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
[$250] Expense - Tax name is not shown in merchant rule system message #83174
Version Number: V9 3.24-1 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:#82438 Email or phone of affected tester (no customers):dreamnitethedragon@gmail.com Issue reported by: Applause Internal Team Bug source: Exploratory - Significant User Experience Deterioration Device used: Redminote 10S Android 13 App Component: Money Requests
Action Performed:
Pre-condition: Have workspace with tag enabled & added, tax , rules enabled
Launch app
Go to workspace settings - Rules
Add merchant rule
Merchant Hi
Updates to
Merchant - star merchant
Category - advertising
Tag - hrllo
Tax - Shahrukh tax 5%
Description - Shahrukh Khan description short
Open workspace chat
Create manual expense with merchant "Hi"
Open the expense
Note system message
set the category to "Advertising", description to "Shahrukh Khan description short", merchant to "Star merchant", tag to "Hrllo", and tax rate to "Tax" via workspace rules
Expected Result:
Tax name must be shown in system message like category, tag, description and merchant.
Actual Result:
Tax name is not shown in system message like category, tag, description and merchant.
👋 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 causing PR (#82438) simply removed the production gate for merchant rules - it did not introduce new functionality, just enabled an existing feature. The bug was latent in the merchant rules implementation but was not caught until the feature was enabled for all users.
Labels: No label changes needed - this is a backend issue. Keep DeployBlockerCash as the fix requires backend changes.
Detailed Analysis
Evidence
The issue reports that when a merchant rule sets a tax rate on an expense, the system message shows:
"set the category to "Advertising", description to "Shahrukh Khan description short", merchant to "Star merchant", tag to "Hrllo", and tax rate to "Tax" via workspace rules"
Notice it says tax rate to "Tax" instead of showing the actual tax name "Shahrukh tax 5%".
Root Cause
The frontend code is correct and has proper handling for tax names:
src/libs/ModifiedExpenseMessage.ts (lines 220-224) extracts the tax name:
Unit tests in tests/unit/ModifiedExpenseMessageTest.ts (lines 863-887) verify this functionality works correctly when the data structure is properly populated.
Type definitions in src/types/onyx/OriginalMessage.ts and src/types/onyx/ExpenseRule.ts show the expected structure:
tax?: {
field_id_TAX: PolicyRuleTaxRate;// { externalID, value, name }};
Backend Issue
The backend is not populating the policyRulesModifiedFields.tax.field_id_TAX.name field correctly when applying merchant rules. The frontend receives the data structure but the name field is either missing or contains a placeholder value ("Tax") instead of the actual tax rate name.
This is a backend bug in the merchant rules application logic that needs to be fixed by the backend team. The backend code (likely in Web-Expensify or PHP codebase) needs to ensure it includes the full tax rate details including the name when populating policyRulesModifiedFields.
Fix Location
Backend: Web-Expensify repository - merchant rule application logic needs to populate tax name
Not an App (frontend) bug: The frontend code correctly handles the data structure when properly provided
This is a backend issue. In OpenReport, the MODIFIEDEXPENSE payload has policyRulesModifiedFields.tax.field_id_TAX.name = "Tax" while the same response has the correct rate name in policy.taxRates.taxes[id_TAX_RATE_1].name = "Test Tax Rate 1" The app only renders field_id_TAX.name, so BE should populate that field with the specific tax rate name (policy.taxRates.taxes[externalID].name), not the container label.
Activity
melvin-bot commentedon Feb 23, 2026
@luacmartins recently merged #82438, but they are OOO right now, so I'll auto-assign someone else.
melvin-bot commentedon Feb 23, 2026
Triggered auto assignment to @stephanieelliott (
Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.melvin-bot commentedon Feb 23, 2026
Triggered auto assignment to @grgia (
DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.melvin-bot commentedon Feb 23, 2026
💬 A slack conversation has been started in #expensify-open-source
github-actions commentedon Feb 23, 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 Feb 23, 2026
Investigation Summary
Classification: Backend bug
Causing PR: #82438 - "Enable merchant rules v2" by @luacmartins (High confidence)
Related PRs:
Recommendation: NEEDS INVESTIGATION (Backend team)
The causing PR (#82438) simply removed the production gate for merchant rules - it did not introduce new functionality, just enabled an existing feature. The bug was latent in the merchant rules implementation but was not caught until the feature was enabled for all users.
Labels: No label changes needed - this is a backend issue. Keep
DeployBlockerCashas the fix requires backend changes.Detailed Analysis
Evidence
The issue reports that when a merchant rule sets a tax rate on an expense, the system message shows:
Notice it says
tax rate to "Tax"instead of showing the actual tax name "Shahrukh tax 5%".Root Cause
The frontend code is correct and has proper handling for tax names:
src/libs/ModifiedExpenseMessage.ts(lines 220-224) extracts the tax name:Unit tests in
tests/unit/ModifiedExpenseMessageTest.ts(lines 863-887) verify this functionality works correctly when the data structure is properly populated.Type definitions in
src/types/onyx/OriginalMessage.tsandsrc/types/onyx/ExpenseRule.tsshow the expected structure:Backend Issue
The backend is not populating the
policyRulesModifiedFields.tax.field_id_TAX.namefield correctly when applying merchant rules. The frontend receives the data structure but thenamefield is either missing or contains a placeholder value ("Tax") instead of the actual tax rate name.This is a backend bug in the merchant rules application logic that needs to be fixed by the backend team. The backend code (likely in Web-Expensify or PHP codebase) needs to ensure it includes the full tax rate details including the name when populating
policyRulesModifiedFields.Fix Location
6 remaining items
melvin-bot commentedon Feb 23, 2026
Job added to Upwork: https://www.upwork.com/jobs/~022025799772686655449
marufsharifi commentedon Feb 23, 2026
This is a backend issue. In
OpenReport, theMODIFIEDEXPENSEpayload haspolicyRulesModifiedFields.tax.field_id_TAX.name = "Tax"while the same response has the correct rate name inpolicy.taxRates.taxes[id_TAX_RATE_1].name = "Test Tax Rate 1"The app only rendersfield_id_TAX.name, so BE should populate that field with the specific tax rate name (policy.taxRates.taxes[externalID].name), not the container label.luacmartins commentedon Feb 23, 2026
#82438 was reverted so this is NAB.
luacmartins commentedon Feb 24, 2026
PR in review
luacmartins commentedon Mar 3, 2026
PR deployed