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-26] [Due for payment 2026-05-26] Expense - New report opens on Inbox when created via upgrade flow on Spend tab #90854
Version Number: 9.3.75-0 Reproducible in staging?: Yes Reproducible in production?: No If this was caught during regression testing, add the test name, ID and link from BrowserStack:#88374 Email or phone of affected tester (no customers):sdsdjoijdoisnjodis@gmail.com Issue reported by: Applause Internal Team Bug source: Exploratory - Significant User Experience Deterioration Device used: Mac 26.2 / Chrome App Component: Money Requests
Action Performed:
Go to staging.new.expensify.com
Create a new account.
Create a new workspace.
Go to Spend > Reports.
Click Create report.
→ New report opens in RHP on Spend tab.
Delete the report.
Delete the workspace.
Go to Spend > Reports.
Click Create report.
Click Upgrade > Confirm > Got it, thanks.
Expected Result:
New report will open in RHP on Spend tab.
Actual Result:
New report opens on Inbox when created via upgrade flow on Spend tab.
👋 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.
Classification: Frontend bug Causing PR: #88374 - "Reapply: Show Create Report CTA for users without a workspace" by @mukhrr (High confidence) Related Issues: #83782, #84139
Recommendation: REVERT
PR #88374 changed the post-upgrade navigation in IOURequestStepUpgrade.tsx in a way that breaks the expected navigation context. The fix is straightforward — revert this PR.
The issue is staging-only (not reproducible in production), which places it squarely in the set of PRs introduced in the current staging deploy. The melvin-bot already flagged PR #88374, which was merged on 2026-05-15 and is listed in the StagingDeployCash checklist.
The reproduction steps confirm the problem only surfaces when going through the upgrade flow from the Spend tab:
This navigated to NewReportWorkspaceSelectionPage, which called its own navigateToNewReport helper. That helper correctly checks isSearchTopmostFullScreenRoute() and conditionally uses ROUTES.SEARCH_MONEY_REQUEST_REPORT vs ROUTES.REPORT_WITH_ID with the appropriate forceReplace logic that considers isRHPOnReportInSearch and shouldUseNarrowLayout.
This bypasses all the context-aware navigation logic in NewReportWorkspaceSelectionPage. It navigates unconditionally to ROUTES.REPORT_WITH_ID with forceReplace: true. When the user is on the Spend tab, forceReplace replaces the current RHP screen with a top-level report route, which causes the navigation to land on the Inbox rather than keeping the report in the RHP context on the Spend tab.
The PR modifies src/pages/iou/request/step/IOURequestStepUpgrade.tsx (confirmed in the file list: src/pages/iou/request/step/IOURequestStepUpgrade.tsx with +12/-4). This file is directly on the code path described in the reproduction steps.
Root Cause
In IOURequestStepUpgrade.tsx, PR #88374 eliminated the intermediate navigation step through NewReportWorkspaceSelectionPage and instead navigates directly to ROUTES.REPORT_WITH_ID with forceReplace: true. The NewReportWorkspaceSelectionPage.navigateToNewReport function has important context-checking logic (e.g., isSearchTopmostFullScreenRoute(), isRHPOnReportInSearch, shouldUseNarrowLayout) that determines how to place the new report in the navigation stack. By bypassing this page, the navigation context is lost and the report opens in the wrong location — the Inbox — instead of in the RHP on the Spend tab.
After the upgrade flow completes (Upgrade > Confirm > Got it, thanks), IOURequestStepUpgrade.tsx:206 always navigates to ROUTES.REPORT_WITH_ID (route r/:reportID), which opens the report in the Inbox tab. It does not check whether the user initiated the flow from the Spend tab.
Other code paths that create reports correctly branch based on the originating tab — e.g. CreateReportMenuItem.tsx:89 uses isSearchTopmostFullScreenRoute() to choose between SEARCH_MONEY_REQUEST_REPORT (stays on Spend) and REPORT_WITH_ID (Inbox). The upgrade path was simply missing this check.
What changes do you think we should make in order to solve the problem?
In src/pages/iou/request/step/IOURequestStepUpgrade.tsx, the UPGRADE_PATHS.REPORTS case with action === CREATE should use isSearchTopmostFullScreenRoute() to pick the correct route, matching the pattern in CreateReportMenuItem.tsx:
If the user is on the Search/Spend tab → navigate to ROUTES.SEARCH_MONEY_REQUEST_REPORT.getRoute({reportID: newReportID, backTo: Navigation.getActiveRoute()})
Otherwise → navigate to ROUTES.REPORT_WITH_ID.getRoute(newReportID) (current behavior)
What alternative solutions did you explore? (Optional)
An alternative would be to pass the originating tab as a route parameter through the upgrade flow. However, isSearchTopmostFullScreenRoute() already solves this problem reliably (the upgrade screen is an RHP overlay, so the underlying full-screen route is still the Search navigator when coming from Spend), and it's the established pattern used by CreateReportMenuItem, NewReportWorkspaceSelectionPage, and EmptySearchView.
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.
Was there a reason @eVoloshchak wasn't assigned to review the PR? Guessing they weren't available and this was a timely deploy blocker.
Reminder: each time new folks handle regression issues, there's a cost. Whenever possible, please try to assign the people originally responsible. Thanks
Activity
melvin-bot commentedon May 16, 2026
You have been assigned to this deploy blocker because you recently merged this PR: #88374
melvin-bot commentedon May 16, 2026
💬 A slack conversation has been started in #expensify-open-source
github-actions commentedon May 16, 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:
OSBotify commentedon May 16, 2026
Investigation Summary
Classification: Frontend bug
Causing PR: #88374 - "Reapply: Show Create Report CTA for users without a workspace" by @mukhrr (High confidence)
Related Issues: #83782, #84139
Recommendation: REVERT
PR #88374 changed the post-upgrade navigation in
IOURequestStepUpgrade.tsxin a way that breaks the expected navigation context. The fix is straightforward — revert this PR.Assigned: @mukhrr (PR author), @eVoloshchak (approving reviewer), @marcaaron (approving reviewer)
Labels:
DeployBlockerCashkept (frontend App bug).DeployBlockernot present, no changes needed.Detailed Analysis
Evidence
The issue is staging-only (not reproducible in production), which places it squarely in the set of PRs introduced in the current staging deploy. The melvin-bot already flagged PR #88374, which was merged on 2026-05-15 and is listed in the
StagingDeployCashchecklist.The reproduction steps confirm the problem only surfaces when going through the upgrade flow from the Spend tab:
Verification
The affected code path is in
src/pages/iou/request/step/IOURequestStepUpgrade.tsx, specifically in theCONST.UPGRADE_PATHS.REPORTScase.Before PR #88374 (the old behavior):
This navigated to
NewReportWorkspaceSelectionPage, which called its ownnavigateToNewReporthelper. That helper correctly checksisSearchTopmostFullScreenRoute()and conditionally usesROUTES.SEARCH_MONEY_REQUEST_REPORTvsROUTES.REPORT_WITH_IDwith the appropriateforceReplacelogic that considersisRHPOnReportInSearchandshouldUseNarrowLayout.After PR #88374 (the broken behavior):
This bypasses all the context-aware navigation logic in
NewReportWorkspaceSelectionPage. It navigates unconditionally toROUTES.REPORT_WITH_IDwithforceReplace: true. When the user is on the Spend tab,forceReplacereplaces the current RHP screen with a top-level report route, which causes the navigation to land on the Inbox rather than keeping the report in the RHP context on the Spend tab.The PR modifies
src/pages/iou/request/step/IOURequestStepUpgrade.tsx(confirmed in the file list:src/pages/iou/request/step/IOURequestStepUpgrade.tsxwith +12/-4). This file is directly on the code path described in the reproduction steps.Root Cause
In
IOURequestStepUpgrade.tsx, PR #88374 eliminated the intermediate navigation step throughNewReportWorkspaceSelectionPageand instead navigates directly toROUTES.REPORT_WITH_IDwithforceReplace: true. TheNewReportWorkspaceSelectionPage.navigateToNewReportfunction has important context-checking logic (e.g.,isSearchTopmostFullScreenRoute(),isRHPOnReportInSearch,shouldUseNarrowLayout) that determines how to place the new report in the navigation stack. By bypassing this page, the navigation context is lost and the report opens in the wrong location — the Inbox — instead of in the RHP on the Spend tab.MelvinBot commentedon May 16, 2026
Proposal
What is the root cause of that problem?
After the upgrade flow completes (Upgrade > Confirm > Got it, thanks),
IOURequestStepUpgrade.tsx:206always navigates toROUTES.REPORT_WITH_ID(router/:reportID), which opens the report in the Inbox tab. It does not check whether the user initiated the flow from the Spend tab.Other code paths that create reports correctly branch based on the originating tab — e.g.
CreateReportMenuItem.tsx:89usesisSearchTopmostFullScreenRoute()to choose betweenSEARCH_MONEY_REQUEST_REPORT(stays on Spend) andREPORT_WITH_ID(Inbox). The upgrade path was simply missing this check.What changes do you think we should make in order to solve the problem?
In
src/pages/iou/request/step/IOURequestStepUpgrade.tsx, theUPGRADE_PATHS.REPORTScase withaction === CREATEshould useisSearchTopmostFullScreenRoute()to pick the correct route, matching the pattern inCreateReportMenuItem.tsx:ROUTES.SEARCH_MONEY_REQUEST_REPORT.getRoute({reportID: newReportID, backTo: Navigation.getActiveRoute()})ROUTES.REPORT_WITH_ID.getRoute(newReportID)(current behavior)What alternative solutions did you explore? (Optional)
An alternative would be to pass the originating tab as a route parameter through the upgrade flow. However,
isSearchTopmostFullScreenRoute()already solves this problem reliably (the upgrade screen is an RHP overlay, so the underlying full-screen route is still the Search navigator when coming from Spend), and it's the established pattern used byCreateReportMenuItem,NewReportWorkspaceSelectionPage, andEmptySearchView.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.21 remaining items
melvin-bot commentedon May 26, 2026
Payment Summary
Upwork Job
BugZero Checklist (@mallenexpensify)
mallenexpensify commentedon May 27, 2026
Payment Summary
Contributor+: @aimane-chnaif paid $250 via Upwork
@aimane-chnaif can you please accept the job below? Please reply here and tag me once you have.
https://www.upwork.com/jobs/~022059771431628573853
Was there a reason @eVoloshchak wasn't assigned to review the PR? Guessing they weren't available and this was a timely deploy blocker.
Reminder: each time new folks handle regression issues, there's a cost. Whenever possible, please try to assign the people originally responsible. Thanks
aimane-chnaif commentedon Jun 2, 2026
@mallenexpensify accepted offer
mallenexpensify commentedon Jun 2, 2026
@aimane-chnaif paid, summary updated above. Thx.