Write On: handle email_unverified launch error in the launch-site flow#112239
Write On: handle email_unverified launch error in the launch-site flow#112239allilevine wants to merge 1 commit into
Conversation
The wpcom launch endpoints now return a 403 `email_unverified` for Write On sites whose owner has an unverified email. In the /start/launch-site flow the `launch` step previously navigated away on mount, so this failure left the user on a blank step with no feedback. Make the step submit the launch once and, when the launch comes back blocked on email verification, render an inline "Verify your email to launch" panel with resend + retry actions. Pending is covered by the flow's own processing screen and success still advances via the flow controller, so the step only renders for the email-verification case. The submit is guarded on step status so the processing screen's unmount/remount cannot spin up a resubmit loop. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YYbEdGDrRcBaiLwmDo8Hg1
Jetpack Cloud Live (direct link)
Automattic for Agencies Live (direct link)
Dashboard Live (dotcom) (direct link)
|
|
Closing this in favor of handling the email-verification prompt in the Write On-owned surface instead of the shared launch flow. Rationale: the The back-end gate (225485-ghe-Automattic/wpcom) is correct and stays: it blocks launch for unverified Write On sites regardless of the client, so the site genuinely stays private. That makes the 403 pure defense-in-depth. New plan: surface the "verify your email to launch" UX in the Write On overlay (which already computes the write-on + unverified Tracked in READ-569. |
Part of READ-569
Proposed Changes
email_unverifiedlaunch error in the/start/launch-siteflow'slaunchstep (client/signup/steps/launch-site). When the launch endpoint returns403 email_unverified, the step now renders an inline "Verify your email to launch" panel with Resend verification email and Try again actions, instead of leaving the user on a blank, silently-failed step.verifyEmail()action for the resend; uses@wordpress/componentsprimitives and design-system color tokens.email_unverified, and the resend + retry actions.Why are these changes being made?
The wpcom launch endpoints now return
403 email_unverifiedfor Write On sites (site_creation_flow = 'write-on') whose owner has an unverified email — companion back-end change 225485-ghe-Automattic/wpcom. Previously thelaunchstep navigated away on mount and swallowed any error, so an unverified author who reached launch (e.g. from the post-publish checklist's Launch CTA) got no feedback and a site that silently stayed private. This gives them an honest, actionable next step. Theemail_unverifiedcode is only ever returned for Write On sites, so the handling is inherently scoped to that flow and every other launch path is unchanged.Testing Instructions
site_creation_flow = 'write-on', Coming Soon), go through/start/launch-site→domains-launch→plans-launch(Free) → thelaunchstep.403 email_unverified; confirm the "Verify your email to launch" panel appears (heading + description + Resend verification email + Try again).Unit tests:
yarn test-client client/signup/steps/launch-site/test/index.jsxPre-merge Checklist
🤖 Generated with Claude Code