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-08-21] Spend - Canadian multiple tax export is not hidden immediately after unreporting expense #98543
Version Number: 9.4.53-0 Reproducible in staging?: Yes Reproducible in production?: N/A - new feature, doesn't exist in prod If this was caught during regression testing, add the test name, ID and link from BrowserStack:#98305 Email or phone of affected tester (no customers):sdsiodjnosdjiodsj@gmail.com Issue reported by: Applause Internal Team Bug source: Exploratory - Significant User Experience Deterioration Device used: Mac 26.5 / Chrome App Component: Search
Action Performed:
Go to staging.new.expensify.com
Create a CAD workspace.
Create an expense in workspace chat.
Go to Spend > Expenses.
Select the expense via checkbox.
Click More > Move to report > Remove from report.
Select the expense via checkbox.
Click More > Export.
→ Canadian multiple tax export is shown.
Go to another tab, then go back to Spend > Expenses.
Repeat Step 7 and 8.
→ Canadian multiple tax export is not shown.
Expected Result:
In Step 8, after removing expense from report, Canadian multiple tax export should be hidden.
Actual Result:
In Step 8, after removing expense from report, Canadian multiple tax export is shown.
In Step 10, after reopening Spend, Canadian multiple tax export is hidden.
👋 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: #98305 - "fix: stop Search re-firing an identical query on unrelated Onyx updates" by @BartekObudzinski (High confidence) Related Issues: #98048 (the performance issue PR #98305 was fixing)
Recommendation: ROLL FORWARD
Reverting #98305 would reintroduce a real cost/perf regression (it eliminated ~26% of redundant Search calls). The regression here is narrow (a stale bulk-action export menu that self-corrects on navigation) and the fix is small and localized: the removeFromReport flow (and its sibling report-change flows) in Search must explicitly refresh the search snapshot after the action, exactly as other flows already do.
Assigned: @BartekObudzinski (PR author), @mountiny and @QichenZhu (approving reviewers) — already auto-assigned to this issue. Labels: No changes. This is a Frontend bug, so DeployBlockerCash stays. There is no DeployBlocker label present, and nothing to remove.
The symptom signature — the export menu shows the wrong option in place, but is correct after navigating away and back — is the classic "stale Search snapshot that is not refetched in place, then refetched fresh on navigation" pattern.
PR fix: stop Search re-firing an identical query on unrelated Onyx updates #98305's own description flags this exact scenario: "a non-chat search no longer refetches on a report action that changes no transaction... The flows that need that refresh already call refreshSearchAfterReportAction explicitly", and "this change also makes the hasDeletedID branch reachable for the first time on non-chat searches, so deletion from search results is worth explicit QA attention."
"Remove from report" changes each transaction's reportID/report membership but does not add or delete a transaction, so the Onyx transaction-ID set is unchanged. It produces report actions.
Before #98305, useSearchHighlightAndScroll.ts triggered a refetch on (!isChat && hasTransactionsIDsChange) || hasReportActionsIDsChange, so the report actions from unreporting would re-fire the expense search and refresh the snapshot in place. After #98305, the condition is (isChat ? hasReportActionsIDsChange : hasTransactionsIDsChange) (L105) — a non-chat expense search now ignores report-action changes entirely. Because the transaction-ID set didn't change either, nothing triggers a refetch.
So after unreporting, the bulk-action menu keeps computing from the stale snapshot (transactions still appear to belong to the CAD workspace policy → doAllSelectedItemsBelongToCADPolicies stays true → "Canadian Multiple Tax Export" still shown). Navigating away and back runs a fresh search whose snapshot has the transactions unreported (policy cleared), so the option is correctly hidden — exactly the reported behavior.
Suggested fix
Add an explicit refreshSearchAfterReportAction call in SearchTransactionsChangeReport.tsx after changeTransactionsReport in removeFromReport (and, for consistency, in selectReport/createReport), mirroring the already-existing usages in useLifecycleActions.tsx and useSelectionModePayment.ts. This restores the in-place refresh for report-membership changes without reviving the redundant Search traffic #98305 removed.
changed the title [-]Spend - Canadian multiple tax export is not hidden immediately after unreporting expense[/-][+][Due for payment 2026-08-21] Spend - Canadian multiple tax export is not hidden immediately after unreporting expense[/+]on Aug 14, 2026
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.4.53-10 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
If no regressions arise, payment will be issued on 2026-08-21. 🎊
The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]. If no checklist is needed for this issue, you can click: [no checklist button]
Activity
applause-bot commentedon Aug 13, 2026
While Applause doesn't embed attachments for this bug, here are the links for quick view:
https://platform.applause.com/services/links/v1/external/373048b6d52859fbc964d40619f4c1e4f17d023d0a063e8c6f571730357df889
melvin-bot commentedon Aug 13, 2026
You have been assigned to this deploy blocker because you recently merged this PR: #98305
melvin-bot commentedon Aug 13, 2026
@mountiny @QichenZhu you have been assigned to this deploy blocker because you reviewed the offending PR: #98305
melvin-bot commentedon Aug 13, 2026
@BartekObudzinski you have been assigned to this deploy blocker because you authored the offending PR: #98305
github-actions commentedon Aug 13, 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:
melvin-bot commentedon Aug 13, 2026
💬 A slack conversation has been started in #expensify-open-source
MelvinBot commentedon Aug 13, 2026
🔍 Investigation Summary
Classification: Frontend bug
Causing PR: #98305 - "fix: stop Search re-firing an identical query on unrelated Onyx updates" by @BartekObudzinski (High confidence)
Related Issues: #98048 (the performance issue PR #98305 was fixing)
Recommendation: ROLL FORWARD
Reverting #98305 would reintroduce a real cost/perf regression (it eliminated ~26% of redundant Search calls). The regression here is narrow (a stale bulk-action export menu that self-corrects on navigation) and the fix is small and localized: the
removeFromReportflow (and its sibling report-change flows) in Search must explicitly refresh the search snapshot after the action, exactly as other flows already do.Assigned: @BartekObudzinski (PR author), @mountiny and @QichenZhu (approving reviewers) — already auto-assigned to this issue.
Labels: No changes. This is a Frontend bug, so
DeployBlockerCashstays. There is noDeployBlockerlabel present, and nothing to remove.📋 Detailed Analysis
Evidence
refreshSearchAfterReportActionexplicitly", and "this change also makes thehasDeletedIDbranch reachable for the first time on non-chat searches, so deletion from search results is worth explicit QA attention."Verification
useSearchBulkActions.tsgetExportOptions(L1692-1714). "Canadian Multiple Tax Export" visibility isincludeMultipleTaxExport = doAllSelectedItemsBelongToCADPolicies, which is derived from the selected transactions'policyIDagainst the Search snapshot (L578-594), and gated ingetExportTemplatesinSearch.tsL1817-1820.removeFromReportinSearchTransactionsChangeReport.tsx(L283-306). It callschangeTransactionsReport(...), thenclearSelectedTransactions()andNavigation.goBack()— it does not callrefreshSearchAfterReportAction, unlike the flows the PR author cited (useLifecycleActions.tsx:252anduseSelectionModePayment.ts:235).Root Cause
"Remove from report" changes each transaction's
reportID/report membership but does not add or delete a transaction, so the Onyx transaction-ID set is unchanged. It produces report actions.Before #98305,
useSearchHighlightAndScroll.tstriggered a refetch on(!isChat && hasTransactionsIDsChange) || hasReportActionsIDsChange, so the report actions from unreporting would re-fire the expense search and refresh the snapshot in place. After #98305, the condition is(isChat ? hasReportActionsIDsChange : hasTransactionsIDsChange)(L105) — a non-chat expense search now ignores report-action changes entirely. Because the transaction-ID set didn't change either, nothing triggers a refetch.So after unreporting, the bulk-action menu keeps computing from the stale snapshot (transactions still appear to belong to the CAD workspace policy →
doAllSelectedItemsBelongToCADPoliciesstays true → "Canadian Multiple Tax Export" still shown). Navigating away and back runs a fresh search whose snapshot has the transactions unreported (policy cleared), so the option is correctly hidden — exactly the reported behavior.Suggested fix
Add an explicit
refreshSearchAfterReportActioncall inSearchTransactionsChangeReport.tsxafterchangeTransactionsReportinremoveFromReport(and, for consistency, inselectReport/createReport), mirroring the already-existing usages inuseLifecycleActions.tsxanduseSelectionModePayment.ts. This restores the in-place refresh for report-membership changes without reviving the redundant Search traffic #98305 removed.melvin-bot commentedon Aug 13, 2026
If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results.
If a regression has occurred and you are the assigned CM follow the instructions here.
If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future.
BartekObudzinski commentedon Aug 13, 2026
PR #98305 was reverted in #98548, so this should no longer reproduce on staging.
melvin-bot commentedon Aug 13, 2026
If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results.
If a regression has occurred and you are the assigned CM follow the instructions here.
If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future.
melvin-bot commentedon Aug 13, 2026
If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results.
If a regression has occurred and you are the assigned CM follow the instructions here.
If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future.
IuliiaHerets commentedon Aug 13, 2026
Not repro on Windows 10/Chrome/Build v9.4.53-3
945cc116a25130c38551ea1787215ab4.mp4
[-]Spend - Canadian multiple tax export is not hidden immediately after unreporting expense[/-][+][Due for payment 2026-08-21] Spend - Canadian multiple tax export is not hidden immediately after unreporting expense[/+]melvin-bot commentedon Aug 14, 2026
@QichenZhu
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.4.53-10 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
If no regressions arise, payment will be issued on 2026-08-21. 🎊
The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]. If no checklist is needed for this issue, you can click: [no checklist button]