Skip to content

Activity Log: Hide backups on WordPress.com plans that don't include them - #55618

Draft
jwebbdev wants to merge 1 commit into
trunkfrom
fix/activity-log-hide-backups-without-self-serve
Draft

jwebbdev wants to merge 1 commit into
trunkfrom
fix/activity-log-hide-backups-without-self-serve

Conversation

@jwebbdev

Copy link
Copy Markdown
Contributor

Proposed changes

Personal and Premium WordPress.com sites on WP Cloud are still backed up in the background, but their plans don't let the owner use those backups. The Backup page and Calypso's Activity Log already hide them on these plans (the Calypso side of this was done in Automattic/wp-calypso#108740). The native WP Admin Activity Log (admin.php?page=jetpack-activity-log) only did that on Simple sites, so on Atomic it still listed daily "Backup and scan complete" events and offered Restore backup on every rewindable row. That restore action leads to the Jetpack Cloud restore flow.

  • Move the hidden-groups check into REST_Controller::get_hidden_groups(), and apply it to WoA sites as well as Simple ones. A site without the backups-self-serve feature hides the rewind and scan groups. Self-hosted Jetpack sites aren't affected.
  • Enforce it on the server: the list and group-count proxies add the hidden groups to not_group. Before this, the free-tier clamp dropped not_group, so a client-side filter alone wouldn't have held on Personal sites.
  • Hide the Restore backup row action when backups are hidden. The action applied to any rewindable event, not just backup rows.
  • Turn off the known-threats lookup on these plans, because it returns backup periods.

Business and higher plans, Jetpack Backup add-ons and staging sites have backups-self-serve, so nothing changes for them.

Related product discussion/links

  • BACKUP-482
  • CMM-2130: the same problem in the Jetpack mobile app
  • CHE-395: Calypso precedent

Does this pull request change what data or activity we track or use?

No.

Testing instructions

On a WoA site with a Premium or Personal plan:

  • Go to WP Admin › Jetpack › Activity Log.
  • Before: "Backup and scan complete" events are listed, and hovering a rewindable row shows Restore backup.
  • After: there are no backup or scan events, the Activity Type filter has no Backup/Scan entries, and no row shows Restore backup.
  • Optional: in the browser console, run wp.apiFetch( { path: '/jetpack/v4/activity-log?group[]=rewind' } ). It should return no backup events.

On a WoA site with a Business plan:

  • The Activity Log still shows backup events, the Restore backup action and known-threat badges, as before.

On a self-hosted Jetpack site with a Backup plan:

  • No change.

Automated tests:

  • jp test php packages/activity-log: the new Hidden_Groups_Test covers WoA and self-hosted sites, the free-tier clamp and group counts.
  • pnpm --filter @automattic/jetpack-activity-log test: the new actions.test.tsx checks the restore action gating.

🤖 Generated with Claude Code

@github-actions

github-actions Bot commented Nov 30, 2026 •

Copy link
Copy Markdown
Contributor

Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.

  • To test on WoA, go to the Plugins menu on a WoA dev site. Click on the "Upload" button and follow the upgrade flow to be able to upload, install, and activate the Jetpack Beta plugin. Once the plugin is active, go to Jetpack > Jetpack Beta, select your plugin (Jetpack), and enable the fix/activity-log-hide-backups-without-self-serve branch.
  • To test on Simple, run the following command on your sandbox:
bin/jetpack-downloader test jetpack fix/activity-log-hide-backups-without-self-serve

Interested in more tips and information?

  • In your local development environment, use the jetpack rsync command to sync your changes to a WoA dev blog.
  • Read more about our development workflow here: PCYsg-eg0-p2
  • Figure out when your changes will be shipped to customers here: PCYsg-eg5-p2

@github-actions

Copy link
Copy Markdown
Contributor

Thank you for your PR!

When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:

  • ✅ Include a description of your PR changes.
  • 🔴 Add a "[Status]" label (In Progress, Needs Review, ...).
  • ✅ Add testing instructions.
  • ✅ Specify whether this PR includes any changes to data or privacy.
  • ✅ Add changelog entries to affected projects

This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖


Follow this PR Review Process:

  1. Ensure all required checks appearing at the bottom of this PR are passing.
  2. Make sure to test your changes on all platforms that it applies to. You're responsible for the quality of the code you ship.
  3. You can use GitHub's Reviewers functionality to request a review.
  4. When it's reviewed and merged, you will be pinged in Slack to deploy the changes to WordPress.com simple once the build is done.

If you have questions about anything, reach out in #jetpack-developers for guidance!

@github-actions github-actions Bot added the [Status] Needs Author Reply We need more details from you. This label will be auto-added until the PR meets all requirements. label Nov 30, 2026
@jp-launch-control

Copy link
Copy Markdown

Code Coverage Summary

Coverage changed in 4 files.

File Coverage Δ% Δ Uncovered
projects/packages/activity-log/src/class-initial-state.php 58/58 (100.00%) 0.00% 0 💚
projects/packages/activity-log/src/js/config.ts 3/3 (100.00%) 0.00% 0 💚
projects/packages/activity-log/src/js/components/ActivityLog/actions.tsx 7/19 (36.84%) 36.84% -7 💚
projects/packages/activity-log/src/class-rest-controller.php 249/275 (90.55%) 15.64% -39 💚

Full summary · PHP report · JS report

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Package] Activity Log [Status] In Progress [Status] Needs Author Reply We need more details from you. This label will be auto-added until the PR meets all requirements. [Tests] Includes Tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant