Skip to content

Enable Jetpack Offline Mode on Studio sites by default (PROTECT-192) - #4705

Draft
agent-sandbox-automattic[bot] wants to merge 1 commit into
trunkfrom
ai/agent/protect-192-1787864372
Draft

Enable Jetpack Offline Mode on Studio sites by default (PROTECT-192)#4705
agent-sandbox-automattic[bot] wants to merge 1 commit into
trunkfrom
ai/agent/protect-192-1787864372

Conversation

@agent-sandbox-automattic

Copy link
Copy Markdown
Contributor

Related issues

  • Related to PROTECT-192 (Enable Jetpack Offline Mode on Studio sites by default)

How AI was used in this PR

Fully AI-generated: the agent located both defaultConstants blocks (one for the Playground runtime, one for the native PHP runtime), added the constant to each, and wrote this PR. The diff was reviewed by the agent before committing.

Proposed Changes

Studio sites now have JETPACK_DEV_DEBUG=true injected into every WordPress configuration, which puts Jetpack into Offline Mode. This ensures Jetpack Account Protection is automatically bypassed on local development sites — users won't hit Jetpack's login protection or other network-dependent Jetpack features when working locally.

The constant is added to the shared defaultConstants object that is applied to every site's blueprint at startup, so the behavior is consistent across both the Playground (WASM) and native PHP runtimes, and works whether or not the user has a custom blueprint.

Testing Instructions

  • Create a new Studio site with Jetpack installed and active.
  • Verify that JETPACK_DEV_DEBUG is true in wp-config.php (e.g. wp eval 'echo JETPACK_DEV_DEBUG;' via Studio's WP-CLI).
  • Confirm that Jetpack Offline Mode is active (wp jetpack status should show offline/development mode).
  • Verify Jetpack Account Protection no longer blocks the local wp-admin login flow.

Pre-merge Checklist

  • Have you checked for TypeScript, React or other console errors?

Note: The node_modules dependency tree was not installed in the sandbox environment, so eslint --fix, npm run typecheck, and npm test could not be executed locally. The change is syntactically straightforward (adding one key-value pair to an existing object literal in two files) and the TypeScript type Record<string, boolean | string> already accommodates boolean values. Please verify CI passes before merging.


Linear: PROTECT-192

This PR was auto-generated by Agent Sandbox. Please review carefully before merging.

…ine Mode

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant