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
[Exploratory] Expense - Tax rate changes to 0% without system message on report when category change #99935
Preconditions: New user signs up with Taxes enabled in Workspace
Open the New Dot app
Navigate to Workspace chat
Create an expense with merchant "Walmart", set tax rate to non-zero
Wait until Concierge suggests the categories pill - select any
Create an expense with merchant "Walmart", set tax rate to non-zero again
Click on the expense to open details
Expected Result:
Concierge changes the tax rate; the user will be notified with a system message. If they don't recheck, they won't know the tax rate has changed on step 5
Actual Result:
After Concierge applies a new Category, the tax rate changes to 0% without a system message notice for the user
Note: the root cause is on the backend, not in Expensify/App. This needs an internal engineer — see below.
What is the root cause of that problem?
When you tap a Concierge category pill, the App does not update the transaction. It posts the chosen category back to Concierge as a plain chat comment and locally hides the pills — nothing else:
src/libs/actions/Report/index.ts:8388-8414 — that resolver only calls addComment (AddComment, params: reportID, reportActionID, reportComment) plus a local-only Onyx.merge to mark the whisper resolved.
No call to updateMoneyRequestCategory, no optimistic transaction write, no optimistic MODIFIED_EXPENSE anywhere on this path. Confirmed by tests/actions/ReportTest.ts:7057-7071, which asserts AddComment is the only command fired.
So both halves of the bug happen server-side: the backend applies the category, resets the tax rate, and does not emit a MODIFIED_EXPENSE report action describing the tax change. The App can already render exactly that message — ModifiedExpenseMessage.ts:454-476 handles tax rate and tax amount changes, and ModifiedExpenseMessage.ts:389-419 even appends "based on past activity" for AI-sourced changes. It simply never receives the tax fields.
One rendering detail worth checking during the fix: the tax fragments require both keys of a pair (oldTaxRate + taxRate, or oldTaxAmount + taxAmount). If the backend sends only one, the fragment is silently dropped and the message degrades to the generic "changed the expense".
What changes do you think we should make in order to solve the problem?
This can't be fixed in Expensify/App — please escalate to an internal engineer with backend access. The backend needs to emit a MODIFIED_EXPENSE report action that includes the tax rate/amount change (both old and new values) whenever it changes tax as a side effect of applying a category.
Related App-side gap (separate path, same shape)
A manual category edit has the same missing-message problem, and this half is in App:
CategoryUtils.ts:99-110 falls back to the workspace default rate when the picked category has no rule of its own — which is how a manually chosen rate silently becomes 0%.
But ReportUtils.ts:6429-6453 gates the tax fragments on taxCode/taxAmount being in transactionChanges, and a category edit passes {category} only — so the optimistic action records the category and nothing else. UpdateMoneyRequestTest.ts:190-220 locks this in today, so any fix must update that test.
Note the suppression there is deliberate (the comments say tax messages are skipped when tax changes as a side effect of a currency change). Extending it to cover category-driven tax changes is a product decision, not just a bug fix, and it would need to stay in sync with the backend's version of the same message.
What alternative solutions did you explore?
The App zeroes the tax optimistically on the pill path — ruled out: the pill path writes nothing to the transaction at all.
The App receives the message but filters it out — possible but unlikely; worth confirming from the report action payload for the repro transaction (does its originalMessage contain any taxRate/oldTaxRate keys, or only category/oldCategory + source: agentZero?). If it contains exactly one key of a pair, the fix flips to App-side.
Confidence and what I couldn't verify
Medium. The App-side evidence is direct and complete. I could not read the backend code, and my attempt to reproduce this in a live web session was blocked by test infrastructure (the browser session came up blank), so the backend behavior is inferred from the App evidence rather than observed.
Next Steps for Contributor+ team: To accept:@MelvinBot implement [this](https://github.com/Expensify/App/issues/99935) to create a draft PR. To refine:@MelvinBot <your feedback> To reject: Explain why you are rejecting Melvin's proposal.
I checked the retest video. The tax rate still changes to 0%, but now Concierge adds a system message in the expense thread: "changed the tax rate to 0% (previously 5%)". This is the expected result for this issue. Closing as completed.
Activity
applause-bot commentedon Aug 31, 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/3f77ced581ea0edbca33d2be8fa233cbcc27bfa3d7ad4acb5d31e5297d480210
MelvinBot commentedon Sep 5, 2026
Proposal
What is the root cause of that problem?
When you tap a Concierge category pill, the App does not update the transaction. It posts the chosen category back to Concierge as a plain chat comment and locally hides the pills — nothing else:
Code evidence for the pill path
src/pages/inbox/report/actionContents/ChatActionableButtons.tsx:84-122— the pill'sonPresscallsresolveConciergeCategoryOptions.src/libs/actions/Report/index.ts:8388-8414— that resolver only callsaddComment(AddComment, params:reportID,reportActionID,reportComment) plus a local-onlyOnyx.mergeto mark the whisper resolved.updateMoneyRequestCategory, no optimistic transaction write, no optimisticMODIFIED_EXPENSEanywhere on this path. Confirmed bytests/actions/ReportTest.ts:7057-7071, which assertsAddCommentis the only command fired.So both halves of the bug happen server-side: the backend applies the category, resets the tax rate, and does not emit a
MODIFIED_EXPENSEreport action describing the tax change. The App can already render exactly that message —ModifiedExpenseMessage.ts:454-476handles tax rate and tax amount changes, andModifiedExpenseMessage.ts:389-419even appends "based on past activity" for AI-sourced changes. It simply never receives the tax fields.One rendering detail worth checking during the fix: the tax fragments require both keys of a pair (
oldTaxRate+taxRate, oroldTaxAmount+taxAmount). If the backend sends only one, the fragment is silently dropped and the message degrades to the generic "changed the expense".What changes do you think we should make in order to solve the problem?
This can't be fixed in
Expensify/App— please escalate to an internal engineer with backend access. The backend needs to emit aMODIFIED_EXPENSEreport action that includes the tax rate/amount change (both old and new values) whenever it changes tax as a side effect of applying a category.Related App-side gap (separate path, same shape)
A manual category edit has the same missing-message problem, and this half is in App:
TransactionUtils/index.ts:1019-1027rewritestaxCode/taxAmount/taxValuefrom the category's tax rule when the category changes.CategoryUtils.ts:99-110falls back to the workspace default rate when the picked category has no rule of its own — which is how a manually chosen rate silently becomes 0%.ReportUtils.ts:6429-6453gates the tax fragments ontaxCode/taxAmountbeing intransactionChanges, and a category edit passes{category}only — so the optimistic action records the category and nothing else.UpdateMoneyRequestTest.ts:190-220locks this in today, so any fix must update that test.Note the suppression there is deliberate (the comments say tax messages are skipped when tax changes as a side effect of a currency change). Extending it to cover category-driven tax changes is a product decision, not just a bug fix, and it would need to stay in sync with the backend's version of the same message.
What alternative solutions did you explore?
originalMessagecontain anytaxRate/oldTaxRatekeys, or onlycategory/oldCategory+source: agentZero?). If it contains exactly one key of a pair, the fix flips to App-side.Confidence and what I couldn't verify
Medium. The App-side evidence is direct and complete. I could not read the backend code, and my attempt to reproduce this in a live web session was blocked by test infrastructure (the browser session came up blank), so the backend behavior is inferred from the App evidence rather than observed.
Possibly related issues
Next Steps for Contributor+ team:
To accept:
@MelvinBot implement [this](https://github.com/Expensify/App/issues/99935)to create a draft PR.To refine:
@MelvinBot <your feedback>To reject: Explain why you are rejecting Melvin's proposal.
view run · no recording available
melvin-bot commentedon Sep 5, 2026
Triggered auto assignment to Contributor-plus team member for initial proposal review - @getusha (
External)melvin-bot commentedon Sep 5, 2026
Unable to auto-create job on Upwork. The BZ team member should create it manually for this issue.
melvin-bot commentedon Sep 9, 2026
@getusha Whoops! This issue is 2 days overdue. Let's get this updated quick!
29 remaining items
melvin-bot commentedon Oct 8, 2026
Triggered auto assignment to @mollfpr, see https://stackoverflow.com/c/expensify/questions/7972 for more details.
melvin-bot commentedon Oct 13, 2026
@getusha Huh... This is 4 days overdue. Who can take care of this?
mollfpr commentedon Oct 14, 2026
Yup, I agree Melvin proposal looks right to me.
I will check the
MODIFIED_EXPENSEpayload for the repro transaction to confirm. If it has no tax keys, I will make the backend fix.mollfpr commentedon Oct 19, 2026
Requested retest.
IuliiaHerets commentedon Oct 19, 2026
Reproduced on Windows 10/Chrome/Prod build v9.5.12-1
2026-10-19.12-39-12.mp4
melvin-bot commentedon Oct 22, 2026
@mollfpr Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!
mollfpr commentedon Oct 26, 2026
I checked the retest video. The tax rate still changes to 0%, but now Concierge adds a system message in the expense thread: "changed the tax rate to 0% (previously 5%)". This is the expected result for this issue. Closing as completed.