:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
fix(onboarding): exempt /account from the onboarding redirect loop (#69355)
posthog[bot]42b680d163fa
diff --git a/frontend/src/scenes/sceneLogic.test.ts b/frontend/src/scenes/sceneLogic.test.tsindex d0420e38cfd6..643f83632f33 100644--- a/frontend/src/scenes/sceneLogic.test.ts+++ b/frontend/src/scenes/sceneLogic.test.ts@@ -2,11 +2,14 @@ import { isOnboardingNotRequiredForPath, withForwardedSearchParams } from './scedescribe('sceneLogic', () => {describe('isOnboardingNotRequiredForPath', () => {- // Regression guard: a mid-onboarding user clicking the email-change confirmation link must not- // be bounced to /onboarding before verifyEmailLogic can run, or the email is never updated.+ // Regression guard: mid-onboarding users hitting auth/account round-trips (email-change+ // confirmation, credential/passkey review) must not be bounced to /onboarding before the+ // scene's own logic can run, or the flow is swallowed and never completes.it.each<[string, boolean]>([['/verify_email/some-uuid/some-token', true],['/project/492200/verify_email/some-uuid/some-token', true],+ ['/account/credential-review', true],+ ['/project/492200/account/credential-review', true],['/project/492200/dashboard/1', false],])('isOnboardingNotRequiredForPath(%s) === %s', (path, expected) => {expect(isOnboardingNotRequiredForPath(path)).toBe(expected)diff --git a/frontend/src/scenes/sceneLogic.tsx b/frontend/src/scenes/sceneLogic.tsxindex 7c47b57a78e6..a9326dd6f76a 100644--- a/frontend/src/scenes/sceneLogic.tsx+++ b/frontend/src/scenes/sceneLogic.tsx@@ -98,6 +98,10 @@ const pathPrefixesOnboardingNotRequiredFor = ['/integrations',// /account-connected/<kind> — return after linking GitHub etc.; /complete/github-link/ redirects here.'/account-connected',+ // /account/* — credential/passkey round-trips (e.g. /account/credential-review) must complete+ // even when onboarding is incomplete, else finishing security setup bounces straight back to+ // /onboarding and the user is stuck in a redirect loop.+ '/account',// /oauth/authorize and any /oauth/* callback path.'/oauth',// /connect/vercel/link (urls.vercelConnect) and other connect round-trips.