Skip to content

[CP STG] Revert "Use threadReportID for report lookup in ReviewTaxCode" - #88155

Merged
stitesExpensify merged 1 commit into
mainfrom
revert-87943-claude-fixReviewTaxCodeTransactionID
Apr 16, 2026
Merged

stitesExpensify merged 1 commit into
mainfrom
revert-87943-claude-fixReviewTaxCodeTransactionID

Conversation

@stitesExpensify

@stitesExpensify stitesExpensify commented Apr 16, 2026 •

Copy link
Copy Markdown
Contributor

Reverts #87943

Fixes 2 deploy blockers:
#88035
#88032

@stitesExpensify
stitesExpensify requested review from a team as code owners April 16, 2026 21:19
@melvin-bot
melvin-bot Bot requested review from Valforte and heyjennahay and removed request for a team April 16, 2026 21:19
@melvin-bot

melvin-bot Bot commented Apr 16, 2026

Copy link
Copy Markdown

@Valforte Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button]

@codecov

codecov Bot commented Apr 16, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ Changes either increased or maintained existing code coverage, great job!

Files with missing lines Coverage Δ
src/libs/TransactionUtils/index.ts 83.64% <ø> (+0.14%) ⬆️
src/libs/actions/IOU/Duplicate.ts 88.03% <100.00%> (ø)
src/pages/TransactionDuplicate/Confirmation.tsx 0.00% <0.00%> (ø)
src/pages/TransactionDuplicate/ReviewTaxCode.tsx 0.00% <0.00%> (ø)
... and 11 files with indirect coverage changes

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 4ef2aa60c6

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

const policy = usePolicy(report?.policyID);
const [transactionThreadReport] = useOnyx(`${ONYXKEYS.COLLECTION.REPORT}${route.params.threadReportID}`);
const transactionID = getTransactionID(transactionThreadReport);
const transactionID = getTransactionID(report);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Restore thread report lookup for tax review transaction

reviewDuplicates.reportID is populated from transaction.reportID (expense report) in src/libs/TransactionPreviewUtils.ts:93, but getTransactionID() only resolves an IOU transaction from a thread report (src/libs/TransactionUtils/index.ts:2547). After this change, ReviewTaxCode derives transactionID from report loaded via reviewDuplicates?.reportID, so the normal path yields undefined and the tax-code review screen cannot reliably load the transaction/duplicates data needed to present tax options.

Useful? React with 👍 / 👎.

Comment on lines 2579 to 2583
reimbursable: reviewDuplicates?.reimbursable ?? false,
category: reviewDuplicates?.category ?? '',
tag: reviewDuplicates?.tag ?? '',
taxCode: reviewDuplicates?.taxCode ?? '',
merchant: reviewDuplicates?.merchant ?? '',
comment: reviewDuplicates?.description ?? '',

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Include selected tax code in duplicate merge parameters

The selected tax code from the review flow is now dropped when building merge params: buildMergeDuplicatesParams() no longer forwards reviewDuplicates.taxCode, so downstream merge/resolve actions cannot apply the user’s tax-code choice. In cases where duplicates differ by tax code, confirming the merge can keep the old tax configuration (and derived tax amount) instead of the value the user picked.

Useful? React with 👍 / 👎.

@neil-marcellini neil-marcellini left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

straight revert should be fine

@stitesExpensify stitesExpensify changed the title Revert "Use threadReportID for report lookup in ReviewTaxCode" [CP STG] Revert "Use threadReportID for report lookup in ReviewTaxCode" Apr 16, 2026
@stitesExpensify
stitesExpensify merged commit 29401f1 into main Apr 16, 2026
38 of 42 checks passed
@stitesExpensify
stitesExpensify deleted the revert-87943-claude-fixReviewTaxCodeTransactionID branch April 16, 2026 21:37
@melvin-bot melvin-bot Bot added the Emergency label Apr 16, 2026
@melvin-bot

melvin-bot Bot commented Apr 16, 2026

Copy link
Copy Markdown

@stitesExpensify looks like this was merged without a test passing. Please add a note explaining why this was done and remove the Emergency label if this is not an emergency.

@stitesExpensify

Copy link
Copy Markdown
Contributor Author

Not an emergency, straight revert

@github-actions

Copy link
Copy Markdown
Contributor

🚧 @stitesExpensify has triggered a test Expensify/App build. You can view the workflow run here.

OSBotify pushed a commit that referenced this pull request Apr 16, 2026
…wTaxCodeTransactionID

[CP STG] Revert "Use threadReportID for report lookup in ReviewTaxCode"

(cherry picked from commit 29401f1)

(cherry-picked to staging by mountiny)
@OSBotify OSBotify added the CP Staging marks PRs that have been CP'd to staging label Apr 16, 2026
@OSBotify

Copy link
Copy Markdown
Contributor

✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release.

@OSBotify

Copy link
Copy Markdown
Contributor

🚀 Cherry-picked to staging by https://github.com/mountiny in version: 9.3.60-10 🚀

platform result
🕸 web 🕸 success ✅
🤖 android 🤖 success ✅
🍎 iOS 🍎 success ✅

Bundle Size Analysis (Sentry):

@MelvinBot

Copy link
Copy Markdown
Contributor

No help site changes are required.

This PR reverts #87943, removing internal taxCode/taxAmount/taxValue parameters from the duplicate transaction merge/resolve API flow. All changes are in internal code (API params, optimistic Onyx data, tests) — no user-facing behavior, UI labels, workflows, or feature names changed. The existing help site articles about duplicate expenses remain accurate.

@OSBotify

Copy link
Copy Markdown
Contributor

🚀 Cherry-picked to staging by https://github.com/mountiny in version: 9.3.60-12 🚀

platform result
🕸 web 🕸 success ✅
🤖 android 🤖 success ✅
🍎 iOS 🍎 success ✅

Bundle Size Analysis (Sentry):

@MelvinBot

Copy link
Copy Markdown
Contributor

I reviewed the changes in this PR. This is a revert of #87943 to fix deploy blockers #88035 and #88032.

No help site changes are required. The changes are entirely internal — removing taxCode/taxAmount/taxValue parameters from the duplicate transaction merge/resolve API calls and fixing a report lookup in ReviewTaxCode.tsx. The user-facing duplicate expense resolution flow is unchanged.

@OSBotify

Copy link
Copy Markdown
Contributor

🚀 Deployed to production by https://github.com/mountiny in version: 9.3.60-22 🚀

platform result
🕸 web 🕸 success ✅
🤖 android 🤖 success ✅
🍎 iOS 🍎 success ✅

@OSBotify

Copy link
Copy Markdown
Contributor

🚀 Cherry-picked to staging by https://github.com/mountiny in version: 9.3.61-0 🚀

platform result
🕸 web 🕸 success ✅
🤖 android 🤖 success ✅
🍎 iOS 🍎 success ✅

Bundle Size Analysis (Sentry):

@MelvinBot

Copy link
Copy Markdown
Contributor

No help site changes are required for this PR.

This is a revert of #87943, rolling back internal code changes to tax code handling in the duplicate transaction merge/resolve flow. There are no user-facing changes — no new features, removed features, renamed UI elements, or altered user flows that would need documentation updates.

@OSBotify

Copy link
Copy Markdown
Contributor

🚀 Deployed to production by https://github.com/marcaaron in version: 9.3.61-4 🚀

platform result
🕸 web 🕸 success ✅
🤖 android 🤖 success ✅
🍎 iOS 🍎 success ✅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CP Staging marks PRs that have been CP'd to staging

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants