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
Expense - Tax is not saved when changing amount currency and tax rate during bulk edit #107623
Version Number: 9.5.49-2 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:#106067 Email or phone of affected tester (no customers):sdjinosdnjiojdsio@gmail.com Issue reported by: Applause Internal Team Bug source: Exploratory - Significant User Experience Deterioration Device used: Mac 26.5 / Chrome App Component: Money Requests
Action Performed:
Precondition:
Enable Taxes.
Set Tax Rate 1 (5%) as foreign currency default in Tax settings.
Go to staging.new.expensify.com
Go to workspace chat.
Create two expenses.
Open the report.
Bulk select both expenses.
Enter amount and select foreign currency.
Open Tax dropdown and select Tax exempt (0%) rate.
Click Save.
Open any edited expense.
Expected Result:
Tax field will show the selected Tax exempt (0%) rate.
Actual Result:
Tax field shows Tax Rate 1 (5%), which disregards the changes during bulk edit.
👋 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.
The deploy-blocker investigator identified a plausible client-side cause exposed by Update the Edit multiple flow, but the complete failure mechanism remains unconfirmed. Web verification was blocked by a blank app page; the reported bug was neither reproduced nor disproved.
Step
Status
Enable Taxes, configure foreign-currency default, create expenses, and verify bulk-edit tax persistenceBlocked before setup: the app returned zero snapshot nodes. No expenses were created and no request payload was captured.
Investigation findings — preliminary proposal
What is the root cause of that problem? The feature PR newly enables combined amount/currency editing in SearchEditMultiplePage.tsx:370–393. Existing bulk-edit logic then removes fields equal to their original values before serializing the update. If the expenses were already exempt, this can discard an explicitly selected exempt rate while retaining the currency change. The server applying the foreign-currency default would explain the symptom, but that step—and the original expense tax values—was not verified.
What changes do you think we should make? First capture the original tax values and outgoing request. If the explicit selection is omitted, make filtering dependency-aware: preserve the explicitly selected tax code, value, and calculated amount together when currency changes, including zero values. Retain ordinary no-op filtering and existing edit restrictions.
What alternative solutions did you explore? A numeric-zero picker bug is not supported: the dropdown stores a tax-code string. Removing all no-op filtering would be unnecessarily broad. If the request already contains the exempt selection, the proposed filtering fix is insufficient and investigation must follow the response.
Resolution recommendation: Keep the deploy blocker. Prefer a targeted fix only after payload confirmation; otherwise consider reverting the feature before deployment. Regression coverage should assert both expenses’ request payloads and tax rates after save and refresh, covering initially exempt and mixed-rate expenses.
Code investigation confirmed that bulk editing can discard an explicitly selected exemption, but did not establish why these expenses subsequently show 5%. Web verification was blocked during workspace tax setup, so the proposal below remains provisional.
Step
Status
Configure workspace taxesCreated a USD workspace, but navigation and overlay limitations prevented enabling Taxes.
❌
Create expenses, bulk-edit to exempt, and verify persistenceNot reached because tax setup was incomplete. No expenses were edited.
❌
Inspect stored tax fields and outgoing updates; develop proposalRequest/response bodies and stored transaction fields were unavailable through the browser tools. Static investigation established the following.
Proposal — provisional
What is the root cause of that problem? Bulk editing constructs the selected tax code, percentage, and amount, then independently removes fields matching each expense’s original values in BulkEdit.ts:374–394. For an already-exempt expense, this drops the explicit exemption while retaining the currency change. However, the optimistic transaction remains exempt; subsequent application of the foreign-currency default is not confirmed.
What changes do you think we should make in order to solve the problem? If the failing request omits the exemption, preserve the accepted tax code, percentage, and calculated amount together whenever currency changes alongside an explicit tax selection—even when those values match the original expense. Apply this after existing eligibility checks; retain ordinary no-op filtering otherwise. Include numeric zero.
What alternative solutions did you explore? A stale label is another possibility: MoneyRequestView.tsx:1049 can prefer an existing taxName over the correctly updated exemption. Preserving the request’s tax fields would not fix that separate display problem.
Required confirmation: Capture original tax fields, outgoing updates, and returned tax fields. Missing exemption identifies the filtering path; exempt stored values with a 5% label identify the display path. The evidence currently does not establish which caused this report.
Regression coverage: Test originally exempt, originally 5%, and mixed-rate expenses. Assert every eligible request’s complete tax bundle, then verify both expenses after save and refresh. Also retain controls for no explicit tax selection and restricted tax editing.
The response still saves Tax Rate 1 (5%) with a €0.48 tax amount. Offline the expense shows Tax exempt, then it flips to 5% when the response arrives. So UpdateMoneyRequest applies the workspace's foreign currency default after a currency change, even when the same request sends a tax code.
Enable Taxes. Leave Tax exempt (0%) as the workspace default and set Tax Rate 1 (5%) as the foreign currency default
Create two USD expenses in the workspace chat and open the report
Select both, click Edit multiple
Enter 10, pick EUR, pick Tax exempt (0%), click Save
Backend fix: in UpdateMoneyRequest, re-apply the default rate after a currency change only when the request sends no taxCode. If one is sent, keep it and use the sent taxValue and taxAmount, even if the code matches the one already stored.
Frontend fix (needed too): bulk edit dropped a tax code equal to the stored one but still sent the new currency, so exempt never reached the server. The fix keeps taxCode, taxValue and taxAmount after removeUnchangedBulkEditFields whenever the currency changes and a rate was picked. PR: #107630
Activity
applause-bot commentedon Nov 20, 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/07159758dc347398374dfa283ef5e8dfdc33b2ab9d8af6f18420ff6ae3f0bc3d
expensify-chore-bot commentedon Nov 20, 2026
You have been assigned to this deploy blocker because you recently merged this PR: #106067
expensify-chore-bot commentedon Nov 20, 2026
@mountiny @ikevin127 you have been assigned to this deploy blocker because you reviewed the offending PR: #106067
expensify-chore-bot commentedon Nov 20, 2026
@DylanDylann you have been assigned to this deploy blocker because you authored the offending PR: #106067
expensify-chore-bot commentedon Nov 20, 2026
💬 A slack conversation has been started in #expensify-open-source
github-actions commentedon Nov 20, 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:
mountiny commentedon Nov 20, 2026
@MelvinBot can you make a proposal to fix this?
MelvinBot commentedon Nov 20, 2026
🤖 Web test steps verification results: ❌ fail
The deploy-blocker investigator identified a plausible client-side cause exposed by Update the Edit multiple flow, but the complete failure mechanism remains unconfirmed. Web verification was blocked by a blank app page; the reported bug was neither reproduced nor disproved.
Enable Taxes, configure foreign-currency default, create expenses, and verify bulk-edit tax persistence
Blocked before setup: the app returned zero snapshot nodes. No expenses were created and no request payload was captured.Investigation findings — preliminary proposal
What is the root cause of that problem?
The feature PR newly enables combined amount/currency editing in SearchEditMultiplePage.tsx:370–393. Existing bulk-edit logic then removes fields equal to their original values before serializing the update. If the expenses were already exempt, this can discard an explicitly selected exempt rate while retaining the currency change. The server applying the foreign-currency default would explain the symptom, but that step—and the original expense tax values—was not verified.
What changes do you think we should make?
First capture the original tax values and outgoing request. If the explicit selection is omitted, make filtering dependency-aware: preserve the explicitly selected tax code, value, and calculated amount together when currency changes, including zero values. Retain ordinary no-op filtering and existing edit restrictions.
What alternative solutions did you explore?
A numeric-zero picker bug is not supported: the dropdown stores a tax-code string. Removing all no-op filtering would be unnecessarily broad. If the request already contains the exempt selection, the proposed filtering fix is insufficient and investigation must follow the response.
Resolution recommendation: Keep the deploy blocker. Prefer a targeted fix only after payload confirmation; otherwise consider reverting the feature before deployment. Regression coverage should assert both expenses’ request payloads and tax rates after save and refresh, covering initially exempt and mixed-rate expenses.
view run · no recording available
MelvinBot commentedon Nov 20, 2026
🤖 Web test steps verification results:⚠️ partial
Code investigation confirmed that bulk editing can discard an explicitly selected exemption, but did not establish why these expenses subsequently show 5%. Web verification was blocked during workspace tax setup, so the proposal below remains provisional.
Configure workspace taxes
Created a USD workspace, but navigation and overlay limitations prevented enabling Taxes.Create expenses, bulk-edit to exempt, and verify persistence
Not reached because tax setup was incomplete. No expenses were edited.Inspect stored tax fields and outgoing updates; develop proposal
Request/response bodies and stored transaction fields were unavailable through the browser tools. Static investigation established the following.Proposal — provisional
What is the root cause of that problem?
Bulk editing constructs the selected tax code, percentage, and amount, then independently removes fields matching each expense’s original values in BulkEdit.ts:374–394. For an already-exempt expense, this drops the explicit exemption while retaining the currency change. However, the optimistic transaction remains exempt; subsequent application of the foreign-currency default is not confirmed.
What changes do you think we should make in order to solve the problem?
If the failing request omits the exemption, preserve the accepted tax code, percentage, and calculated amount together whenever currency changes alongside an explicit tax selection—even when those values match the original expense. Apply this after existing eligibility checks; retain ordinary no-op filtering otherwise. Include numeric zero.
What alternative solutions did you explore?
A stale label is another possibility: MoneyRequestView.tsx:1049 can prefer an existing taxName over the correctly updated exemption. Preserving the request’s tax fields would not fix that separate display problem.
Required confirmation: Capture original tax fields, outgoing updates, and returned tax fields. Missing exemption identifies the filtering path; exempt stored values with a 5% label identify the display path. The evidence currently does not establish which caused this report.
Regression coverage: Test originally exempt, originally 5%, and mixed-rate expenses. Assert every eligible request’s complete tax bundle, then verify both expenses after save and refresh. Also retain controls for no explicit tax selection and restricted tax editing.
view run · view recording
mkhutornyi commentedon Nov 20, 2026
Helping from https://expensify.slack.com/archives/C01GTK53T8Q/p1795213817936429?thread_ts=1795206561.805279&cid=C01GTK53T8Q
mkhutornyi commentedon Nov 20, 2026
The server ignores a tax code sent with a currency change.
With the client fixed to keep the selected rate when the currency changes, bulk edit now sends this to
UpdateMoneyRequest:{"currency":"EUR","taxCode":"id_TAX_EXEMPT","taxValue":"0%","taxAmount":0,"amount":1000}The response still saves Tax Rate 1 (5%) with a €0.48 tax amount. Offline the expense shows Tax exempt, then it flips to 5% when the response arrives. So
UpdateMoneyRequestapplies the workspace's foreign currency default after a currency change, even when the same request sends a tax code.Expected Result: Tax exempt (0%), tax amount €0.00
Actual Result: Tax Rate 1 (5%), tax amount €0.48
Backend fix: in
UpdateMoneyRequest, re-apply the default rate after a currency change only when the request sends notaxCode. If one is sent, keep it and use the senttaxValueandtaxAmount, even if the code matches the one already stored.Frontend fix (needed too): bulk edit dropped a tax code equal to the stored one but still sent the new currency, so exempt never reached the server. The fix keeps
taxCode,taxValueandtaxAmountafterremoveUnchangedBulkEditFieldswhenever the currency changes and a rate was picked. PR: #107630fix.mov
mountiny commentedon Nov 21, 2026
I think we can demote if this issue spans backend as well, I think this is very narrow edge case
ikevin127 commentedon Nov 21, 2026
Does the PR #107630 for this need my review ?
mkhutornyi commentedon Nov 21, 2026
yes eventually. Holding test for backend fix
ikevin127 commentedon Nov 21, 2026
Ok then, please tag me on the PR whenever review is required 🙌