You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Due for payment 2026-05-11] Onboarding-Onboarding modal is not shown after redirecting from OD #89010
Version Number: 9.3.62-7 Reproducible in staging?: Yes Reproducible in production?: No If this was caught during regression testing, add the test name, ID and link from BrowserStack:https://test-management.browserstack.com/projects/2219752/folder/13176677/test-cases/41237671 Email or phone of affected tester (no customers): N/A Issue reported by: Applause Internal Team Bug source: Regression TC Execution Device used: MacBook Air 15.7.4 Chrome App Component: Other
Action Performed:
Open a fresh incognito window
Go to OD - staging.expensify.com
Select "Manage my company's expenses 1-9"
Sign up with a new account without a "+" ([anything]@tstsg.com)
Click on "Get Started", then "Join"
Verify that you are redirected to NewDot and the onboarding modal is displayed
Expected Result:
The onboarding modal is displayed for a new user after being redirected from OD
Actual Result:
Onboarding modal is not shown for a new user after redirecting from OD
👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:
Identify the pull request that introduced this issue and revert it.
When a new user signs up on OldDot and gets redirected to NewDot via /transition, the onboarding modal is skipped due to the isInvitedOrGroupMember check in useOnboardingFlow.ts:86-91.
OldDot's sign-up flow (selecting "Manage my company's expenses 1-9") sets nvp_introSelected with an inviteType, which makes wasInvitedToNewDotSelector return true. It may also create a workspace policy, making hasNonPersonalPolicy true. Either condition causes isInvitedOrGroupMember to be true, and the hook returns early at line 90 — never calling startOnboardingFlow().
Additionally, the OnboardingGuard also skips onboarding because isTransitioning is true (the browser URL still contains "transition" after auth completes) and isInvitedOrGroupMember is also true at the guard level (line 173). So both mechanisms that could trigger onboarding are blocked.
This is not reproducible in production because the current production build predates the code that introduced the isInvitedOrGroupMember skip in the useOnboardingFlowRouter hook and the new OnboardingGuard.
What changes do you think we should make in order to solve the problem?
The isInvitedOrGroupMember check in useOnboardingFlow.ts (line 88-90) should not skip onboarding for users who haven't completed it (hasCompletedGuidedSetupFlow === false). Users coming from OldDot sign-up with nvp_introSelected set still need to go through the NewDot onboarding flow.
The fix should refine the skip condition so that isInvitedOrGroupMember only causes a skip when the user has actually completed onboarding or when the NVP_ONBOARDING data indicates they don't need it. One approach: check isOnboardingCompleted !== false before applying the isInvitedOrGroupMember early return in the hook. The same logic should be reviewed in OnboardingGuard.ts line 173/194 to ensure consistency.
What alternative solutions did you explore? (Optional)
An alternative would be to fix the isTransitioning check timing so that once auth completes and the URL updates from /transition, the guard properly re-evaluates and redirects to onboarding. However, this is fragile and depends on URL update timing. Fixing the isInvitedOrGroupMember logic directly is more reliable since it addresses the core semantic issue: OldDot sign-up users with inviteType set are not the same as users who were genuinely invited to a workspace by another user and don't need onboarding.
Investigation details
Data flow for the bug:
User signs up on OldDot, selects "Manage my company's expenses 1-9"
OldDot sets nvp_introSelected with inviteType and may create a workspace policy
OldDot redirects to new.expensify.com/transition?shortLivedAuthToken=...
LogInWithShortLivedAuthTokenPage authenticates the user
Confidence: High — the code path is clear and both skip mechanisms are well-documented in the source.
Possibly related issue:Expensify/App#86498 — same symptom (onboarding not shown after OD redirect), reported in version 9.3.49-2 and reproducible in both staging and production. That issue may share the same root cause at the OnboardingGuard level, while this deploy blocker regression adds the isInvitedOrGroupMember skip in the hook as a second blocker.
Next Steps for Contributor+ team: Reply with @MelvinBot implement this to create a draft PR, @MelvinBot <your feedback> to refine this analysis, or explain why you are rejecting Melvin's proposal.
Classification: Needs further investigation — may be Frontend or Backend bug Causing PR: No single PR identified with confidence Related Issues: None identified
Recommendation: NEEDS INVESTIGATION
The onboarding flow for OD-to-NewDot redirects on web involves multiple layers (OD backend, transition URL handling, LogInWithShortLivedAuthTokenPage, AuthScreensInitHandler, useOnboardingFlowRouter, and OnboardingGuard). None of the staging PRs I examined clearly broke this specific path.
Assigned: None — no causing PR identified with sufficient confidence Labels: No label changes made — both DeployBlockerCash and DeployBlocker retained pending further investigation
📋 Detailed Analysis
Evidence
Bug summary: After signing up on staging.expensify.com (OD) and being redirected to staging.new.expensify.com (NewDot web) as a new user, the onboarding modal does not appear. This is staging-only and is not reproducible in production.
Platform: MacOS Chrome (web, not native HybridApp).
Transition flow analyzed:
User signs up on OD → OD issues a shortLivedAuthToken and redirects to /transition?shortLivedAuthToken=...&exitTo=...
On the NewDot web side (CONFIG.IS_HYBRID_APP = false), LogInWithShortLivedAuthTokenPage (public screen) calls signInWithShortLivedAuthToken()
After sign-in, SessionUtils.didUserLogInDuringSession() returns true → AuthScreensInitHandler calls App.openApp()
useOnboardingFlowRouter() (in AuthScreens.tsx) runs after isLoadingApp becomes false
startOnboardingFlow() should redirect the user to the onboarding modal
Conditions that skip onboarding (in useOnboardingFlow.ts):
The hook returns early if currentUrl.includes(ROUTES.TRANSITION_BETWEEN_APPS) && isLoggingInAsNewSessionUser. During the transition, this correctly blocks onboarding. After the URL changes to HOME, the hook should re-run and trigger onboarding.
The hook also skips onboarding if hasNonPersonalPolicy is true. For the "Manage my company's expenses 1-9" sign-up path, OD may automatically create a workspace/policy, which would set hasNonPersonalPolicy: true in the openApp response, causing the hook to skip onboarding permanently.
OnboardingGuard conditions (in OnboardingGuard.ts): Similar conditions — isInvitedOrGroupMember = (!CONFIG.IS_HYBRID_APP && (hasNonPersonalPolicy || wasInvitedToNewDot)) would also skip the guard redirect if hasNonPersonalPolicy is true.
PR [Onyx Audit] Migrate keys to RAM-only part 3/3 #86660 "[Onyx Audit] Migrate keys to RAM-only part 3/3" — changes IS_CHECKING_PUBLIC_ROOM to RAM-only and IS_LOADING_REPORT_DATA subscription behavior; merged after 9.3.62-7 so not applicable to this version
None of the examined PRs directly break the OD-to-NewDot web onboarding flow with high confidence.
Root Cause
Hypothesis 1 (Backend): The OD staging environment may have changed how it creates accounts for the "Manage my company's expenses 1-9" path, resulting in the user having hasNonPersonalPolicy: true in the OpenApp response. This would cause both useOnboardingFlowRouter and OnboardingGuard to skip onboarding, since the user appears to already be part of a non-personal workspace. If this is the case, the fix would require investigation on the OD/API side, not in the App.
Hypothesis 2 (Frontend): A timing issue in the new-user sign-in flow causes the onboarding to be skipped. After signInWithShortLivedAuthToken, the useOnboardingFlow hook checks isLoggingInAsNewSessionUser against the current URL. If sessionEmail updates before currentUrl clears the transition path, the check paramsEmail === sessionEmail would be true, making isLoggingInAsNewUser return false. This would not block onboarding, so timing alone shouldn't prevent it.
Recommended next steps:
Confirm what hasNonPersonalPolicy value is set to in the OpenApp response for a new user from the "Manage my company's expenses 1-9" path on staging vs production
Check if the OD staging environment recently changed account creation behavior for company-size selections
Add logging in useOnboardingFlow.ts to capture which condition is causing the early return
changed the title [-][Due for payment 2026-05-11] [Due for payment 2026-05-07] Onboarding-Onboarding modal is not shown after redirecting from OD[/-][+][Due for payment 2026-05-11] Onboarding-Onboarding modal is not shown after redirecting from OD[/+]on May 7, 2026
This issue was introduced by the PR of this issue. Users who are invited to a workspace before completing onboarding are incorrectly shown the onboarding modal when they log back in.
Activity
melvin-bot commentedon Apr 28, 2026
Triggered auto assignment to @inimaga (
DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.melvin-bot commentedon Apr 28, 2026
💬 A slack conversation has been started in #expensify-open-source
github-actions commentedon Apr 28, 2026
👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:
MelvinBot commentedon Apr 28, 2026
Proposal
What is the root cause of that problem?
When a new user signs up on OldDot and gets redirected to NewDot via
/transition, the onboarding modal is skipped due to theisInvitedOrGroupMembercheck inuseOnboardingFlow.ts:86-91.OldDot's sign-up flow (selecting "Manage my company's expenses 1-9") sets
nvp_introSelectedwith aninviteType, which makeswasInvitedToNewDotSelectorreturntrue. It may also create a workspace policy, makinghasNonPersonalPolicytrue. Either condition causesisInvitedOrGroupMemberto betrue, and the hook returns early at line 90 — never callingstartOnboardingFlow().Additionally, the
OnboardingGuardalso skips onboarding becauseisTransitioningistrue(the browser URL still contains "transition" after auth completes) andisInvitedOrGroupMemberis alsotrueat the guard level (line 173). So both mechanisms that could trigger onboarding are blocked.This is not reproducible in production because the current production build predates the code that introduced the
isInvitedOrGroupMemberskip in theuseOnboardingFlowRouterhook and the newOnboardingGuard.What changes do you think we should make in order to solve the problem?
The
isInvitedOrGroupMembercheck inuseOnboardingFlow.ts(line 88-90) should not skip onboarding for users who haven't completed it (hasCompletedGuidedSetupFlow === false). Users coming from OldDot sign-up withnvp_introSelectedset still need to go through the NewDot onboarding flow.The fix should refine the skip condition so that
isInvitedOrGroupMemberonly causes a skip when the user has actually completed onboarding or when theNVP_ONBOARDINGdata indicates they don't need it. One approach: checkisOnboardingCompleted !== falsebefore applying theisInvitedOrGroupMemberearly return in the hook. The same logic should be reviewed inOnboardingGuard.tsline 173/194 to ensure consistency.What alternative solutions did you explore? (Optional)
An alternative would be to fix the
isTransitioningcheck timing so that once auth completes and the URL updates from/transition, the guard properly re-evaluates and redirects to onboarding. However, this is fragile and depends on URL update timing. Fixing theisInvitedOrGroupMemberlogic directly is more reliable since it addresses the core semantic issue: OldDot sign-up users withinviteTypeset are not the same as users who were genuinely invited to a workspace by another user and don't need onboarding.Investigation details
Data flow for the bug:
nvp_introSelectedwithinviteTypeand may create a workspace policynew.expensify.com/transition?shortLivedAuthToken=...LogInWithShortLivedAuthTokenPageauthenticates the userAuthScreensmounts,useOnboardingFlowRouterhook runsOnboardingGuardevaluates:isTransitioning=true→shouldSkipOnboarding=true→ ALLOW (no redirect)wasInvitedToNewDot=true(fromnvp_introSelected.inviteType) →isInvitedOrGroupMember=true→ early return at line 90startOnboardingFlow()is never called → onboarding modal never appearsKey files:
useOnboardingFlow.ts— Hook with theisInvitedOrGroupMemberskip (line 86-91)OnboardingGuard.ts— Guard with same skip condition (line 173, 194)Onboarding.tsselectors —wasInvitedToNewDotSelectorreturns true wheninviteTypeis setConfidence: High — the code path is clear and both skip mechanisms are well-documented in the source.
Possibly related issue: Expensify/App#86498 — same symptom (onboarding not shown after OD redirect), reported in version 9.3.49-2 and reproducible in both staging and production. That issue may share the same root cause at the
OnboardingGuardlevel, while this deploy blocker regression adds theisInvitedOrGroupMemberskip in the hook as a second blocker.Next Steps for Contributor+ team: Reply with
@MelvinBot implement thisto create a draft PR,@MelvinBot <your feedback>to refine this analysis, or explain why you are rejecting Melvin's proposal.OSBotify commentedon Apr 28, 2026
Investigation Summary
Classification: Needs further investigation — may be Frontend or Backend bug
Causing PR: No single PR identified with confidence
Related Issues: None identified
Recommendation: NEEDS INVESTIGATION
The onboarding flow for OD-to-NewDot redirects on web involves multiple layers (OD backend, transition URL handling,
LogInWithShortLivedAuthTokenPage,AuthScreensInitHandler,useOnboardingFlowRouter, andOnboardingGuard). None of the staging PRs I examined clearly broke this specific path.Assigned: None — no causing PR identified with sufficient confidence
Labels: No label changes made — both
DeployBlockerCashandDeployBlockerretained pending further investigation📋 Detailed Analysis
Evidence
Bug summary: After signing up on
staging.expensify.com(OD) and being redirected tostaging.new.expensify.com(NewDot web) as a new user, the onboarding modal does not appear. This is staging-only and is not reproducible in production.Platform: MacOS Chrome (web, not native HybridApp).
Transition flow analyzed:
shortLivedAuthTokenand redirects to/transition?shortLivedAuthToken=...&exitTo=...CONFIG.IS_HYBRID_APP = false),LogInWithShortLivedAuthTokenPage(public screen) callssignInWithShortLivedAuthToken()SessionUtils.didUserLogInDuringSession()returnstrue→AuthScreensInitHandlercallsApp.openApp()useOnboardingFlowRouter()(inAuthScreens.tsx) runs afterisLoadingAppbecomesfalsestartOnboardingFlow()should redirect the user to the onboarding modalConditions that skip onboarding (in
useOnboardingFlow.ts):The hook returns early if
currentUrl.includes(ROUTES.TRANSITION_BETWEEN_APPS) && isLoggingInAsNewSessionUser. During the transition, this correctly blocks onboarding. After the URL changes to HOME, the hook should re-run and trigger onboarding.The hook also skips onboarding if
hasNonPersonalPolicyistrue. For the "Manage my company's expenses 1-9" sign-up path, OD may automatically create a workspace/policy, which would sethasNonPersonalPolicy: truein theopenAppresponse, causing the hook to skip onboarding permanently.OnboardingGuard conditions (in
OnboardingGuard.ts): Similar conditions —isInvitedOrGroupMember = (!CONFIG.IS_HYBRID_APP && (hasNonPersonalPolicy || wasInvitedToNewDot))would also skip the guard redirect ifhasNonPersonalPolicyis true.Verification
Files involved in the flow:
/src/pages/LogInWithShortLivedAuthTokenPage.tsx— handles transition URL authentication/src/libs/Navigation/AppNavigator/AuthScreensInitHandler.tsx— callsopenApp()after sign-in/src/hooks/useOnboardingFlow.ts— triggers onboarding viastartOnboardingFlow()/src/libs/Navigation/guards/OnboardingGuard.ts— guards navigation to redirect to onboardingStaging PRs examined that touch related code:
SignInModal.tsxonly; for anonymous sign-in from public rooms, not OD redirectisOnboardingFocusedcheck toOnboardingGuard.ts; prevents redirect if already on onboardingIS_CHECKING_PUBLIC_ROOMto RAM-only andIS_LOADING_REPORT_DATAsubscription behavior; merged after 9.3.62-7 so not applicable to this versionNone of the examined PRs directly break the OD-to-NewDot web onboarding flow with high confidence.
Root Cause
Hypothesis 1 (Backend): The OD staging environment may have changed how it creates accounts for the "Manage my company's expenses 1-9" path, resulting in the user having
hasNonPersonalPolicy: truein the OpenApp response. This would cause bothuseOnboardingFlowRouterandOnboardingGuardto skip onboarding, since the user appears to already be part of a non-personal workspace. If this is the case, the fix would require investigation on the OD/API side, not in the App.Hypothesis 2 (Frontend): A timing issue in the new-user sign-in flow causes the onboarding to be skipped. After
signInWithShortLivedAuthToken, theuseOnboardingFlowhook checksisLoggingInAsNewSessionUseragainst the current URL. IfsessionEmailupdates beforecurrentUrlclears the transition path, the checkparamsEmail === sessionEmailwould betrue, makingisLoggingInAsNewUserreturnfalse. This would not block onboarding, so timing alone shouldn't prevent it.Recommended next steps:
hasNonPersonalPolicyvalue is set to in the OpenApp response for a new user from the "Manage my company's expenses 1-9" path on staging vs productionuseOnboardingFlow.tsto capture which condition is causing the early returnamyevans commentedon Apr 28, 2026
Looks like a FE PR was identified: #85234 (comment), so removing the
DeployBlockerlabel38 remaining items
[-][Due for payment 2026-05-11] [Due for payment 2026-05-07] Onboarding-Onboarding modal is not shown after redirecting from OD[/-][+][Due for payment 2026-05-11] Onboarding-Onboarding modal is not shown after redirecting from OD[/+]melvin-bot commentedon May 8, 2026
@mallenexpensify Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!
melvin-bot commentedon May 11, 2026
Payment Summary
Upwork Job
BugZero Checklist (@mallenexpensify)
mallenexpensify commentedon May 12, 2026
Payment Summary
Contributor+: @Krishna2323 due $250 via NewDot
Contributor+: @mkhutornyi due $250 via NewDot
Think we're good here, comment/reopen if not
Krishna2323 commentedon May 15, 2026
Requested in ND.
laurenreidexpensify commentedon May 19, 2026
$250 approved for @Krishna2323
trjExpensify commentedon Jun 2, 2026
approved $250 for @mkhutornyi
marufsharifi commentedon Jun 16, 2026
This issue was introduced by the PR of this issue. Users who are invited to a workspace before completing onboarding are incorrectly shown the onboarding modal when they log back in.