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-09-30] Expense - No page count on multi page PDF receipt when created from split scan expense #100350
Version Number: 9.4.70-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:#97813 Email or phone of affected tester (no customers):jsdoijnodsdisojo@gmail.com Issue reported by: Applause Internal Team Bug source: Exploratory - Significant User Experience Deterioration Device used: Mac 26.5 / Chrome App Component: Workspace Settings
Action Performed:
Go to staging.new.expensify.com
Open 1:1 DM with any user.
Create a split scan expense with multi page PDF receipt.
Open the split preview.
Click Show more.
Click Amount.
Enter amount and save it.
Open split preview.
Open the expense report.
Expected Result:
Page count will show on the receipt on split details page and expense report.
Actual Result:
Page count is not shown on the receipt on split details page and expense report.
👋 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.
Root Cause:#97813 (the auto-assigned PR) is correct — but it's not a small miss. The page-count badge only exists in one component, and the split flow misses it in two independent ways:
Expense report — pageCount is stripped from the split's child transactions. buildOptimisticTransaction rebuilds receipt from a four-field whitelist (source, filename, state, isTestDriveReceipt). pageCount isn't in it, so receiptPageCount falls back to 0 and the > 1 gate at MoneyRequestReceiptView.tsx:560 never passes.
Badge covers the Mapbox logo while a distance receipt regenerates
The feature is cosmetic and brand new, so nothing in production depends on it, and #97813 is the last PR to touch every file it changed — the revert is clean. Patching three lifecycle gaps under deploy-blocker time pressure is the riskier path.
If you'd rather roll forward
Two client-side changes are needed for this blocker only:
Add pageCount to the receipt literal in TransactionUtils/index.ts:563-565, or spread the incoming receipt instead of whitelisting fields.
Unverified: whether the backend's CompleteSplitBill propagates pageCount onto the server-created child transactions. Even with both changes, that needs confirming. And neither change touches #100336 or #100342.
Its diff adds pageCount to the Receipt type and updates Receipt.ts, MergeTransaction.ts, DebugUtils.ts and MoneyRequestReceiptView.tsx — but not src/libs/TransactionUtils/index.ts.
grep -rn "pageCount" src/libs src/components shows the only consumer of receipt.pageCount is MoneyRequestReceiptView.tsx:203; no other receipt-rendering component reads it.
completeSplitBill does pass the full receipt through at Split.ts:1104 — the field is lost downstream in buildOptimisticTransaction, not at the call site.
Proposed AI code review rule (for maintainer review)
Repo:Expensify/App — CONSISTENCY-19: Propagate new Onyx model fields through every explicit-field rebuilder.
Condition: When a PR adds a property to a type under src/types/onyx/, every function that returns that model as an object literal with an explicit field list (rather than spreading the source) must copy the new property too — otherwise the field is silently dropped from optimistic data.
Why:buildOptimisticTransaction rebuilds receipt from a four-key whitelist, so the newly added receipt.pageCount never reached split-created transactions and the feature silently did nothing in that flow.
Detection: for each property added under src/types/onyx/, run rg -n "<propName>" src/libs src/components and confirm it appears in every buildOptimistic* / getUpdated* function returning that model.
Not created — a maintainer can open it as a draft PR under .claude/skills/coding-standards/rules/.
Next Steps for Contributor+ team: To accept:@MelvinBot implement [this](https://github.com/Expensify/App/issues/100350) to create a draft PR. To refine:@MelvinBot <your feedback> To reject: Explain why you are rejecting Melvin's proposal.
changed the title [-]Expense - No page count on multi page PDF receipt when created from split scan expense[/-][+][Due for payment 2026-09-30] Expense - No page count on multi page PDF receipt when created from split scan expense[/+]on Sep 23, 2026
[Contributor] The offending PR and associated issue have been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake.
Link to the comment on the PR: new feature
[Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner.
Link to discussion: N/A — new feature
[Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again.
Regression Test Proposal
Precondition:
A multi-page PDF receipt (2+ pages).
Test:
Open a 1:1 DM with any user.
Create a split scan expense using the multi-page PDF receipt.
On the split confirmation screen, verify the "Page 1 of N" badge appears on the receipt thumbnail.
Complete the split (enter amounts, save).
Open the split preview, then open one of the resulting individual expenses.
Verify the "Page 1 of N" badge shows on the expense's receipt with the correct page count.
Open an expense created from a single-page PDF split and verify no badge appears.
Don't think this is a blocker though there was no badge here before #97813 either, so reverting wouldn't restore anything, it'd just remove a badge that never existed for splits.
Paid 100% cuz, from @ishpaul777 's comment, it sounds like the bug pre-existed the PR. Comment/reopen if any disagrees
Activity
applause-bot commentedon Sep 3, 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/2d08f1d14b18c50dc70d25a9995bacd4d79ee39ff27098d6d5c676a296c53725
melvin-bot commentedon Sep 3, 2026
You have been assigned to this deploy blocker because you recently merged this PR: #97813
melvin-bot commentedon Sep 3, 2026
@MonilBhavsar @abzokhattab you have been assigned to this deploy blocker because you reviewed the offending PR: #97813
melvin-bot commentedon Sep 3, 2026
@ishpaul777 you have been assigned to this deploy blocker because you authored the offending PR: #97813
melvin-bot commentedon Sep 3, 2026
💬 A slack conversation has been started in #expensify-open-source
github-actions commentedon Sep 3, 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:
MelvinBot commentedon Sep 3, 2026
Issue Analysis
Root Cause: #97813 (the auto-assigned PR) is correct — but it's not a small miss. The page-count badge only exists in one component, and the split flow misses it in two independent ways:
DynamicSplitBillDetailsPageshows the receipt viaConfirmationReceiptThumbnail.tsx:134-180, which has noBadge. That file isn't in [Payment due @abzokhattab] Show a page count badge on multi-page PDF receipts #97813's diff, so the badge is structurally unreachable on the split preview.pageCountis stripped from the split's child transactions.buildOptimisticTransactionrebuildsreceiptfrom a four-field whitelist (source,filename,state,isTestDriveReceipt).pageCountisn't in it, soreceiptPageCountfalls back to0and the> 1gate atMoneyRequestReceiptView.tsx:560never passes.Recommended Fix: revert #97813.
That PR is the sole cause of three of the four open deploy blockers on this checklist:
The feature is cosmetic and brand new, so nothing in production depends on it, and #97813 is the last PR to touch every file it changed — the revert is clean. Patching three lifecycle gaps under deploy-blocker time pressure is the riskier path.
If you'd rather roll forward
Two client-side changes are needed for this blocker only:
pageCountto the receipt literal inTransactionUtils/index.ts:563-565, or spread the incoming receipt instead of whitelisting fields.ConfirmationReceiptThumbnail.tsx, or explicitly scope the split details page out of the feature.Unverified: whether the backend's
CompleteSplitBillpropagatespageCountonto the server-created child transactions. Even with both changes, that needs confirming. And neither change touches #100336 or #100342.Supporting evidence
pageCountto theReceipttype and updatesReceipt.ts,MergeTransaction.ts,DebugUtils.tsandMoneyRequestReceiptView.tsx— but notsrc/libs/TransactionUtils/index.ts.grep -rn "pageCount" src/libs src/componentsshows the only consumer ofreceipt.pageCountisMoneyRequestReceiptView.tsx:203; no other receipt-rendering component reads it.completeSplitBilldoes pass the full receipt through atSplit.ts:1104— the field is lost downstream inbuildOptimisticTransaction, not at the call site.Proposed AI code review rule (for maintainer review)
Repo:
Expensify/App—CONSISTENCY-19: Propagate new Onyx model fields through every explicit-field rebuilder.Condition: When a PR adds a property to a type under
src/types/onyx/, every function that returns that model as an object literal with an explicit field list (rather than spreading the source) must copy the new property too — otherwise the field is silently dropped from optimistic data.Why:
buildOptimisticTransactionrebuildsreceiptfrom a four-key whitelist, so the newly addedreceipt.pageCountnever reached split-created transactions and the feature silently did nothing in that flow.Detection: for each property added under
src/types/onyx/, runrg -n "<propName>" src/libs src/componentsand confirm it appears in everybuildOptimistic*/getUpdated*function returning that model.Not created — a maintainer can open it as a draft PR under
.claude/skills/coding-standards/rules/.Next Steps for Contributor+ team:
To accept:
@MelvinBot implement [this](https://github.com/Expensify/App/issues/100350)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
12 remaining items
[-]Expense - No page count on multi page PDF receipt when created from split scan expense[/-][+][Due for payment 2026-09-30] Expense - No page count on multi page PDF receipt when created from split scan expense[/+]abzokhattab commentedon Sep 23, 2026
Contributor+ Checklist:
[Contributor] The offending PR and associated issue have been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake.
Link to the comment on the PR: new feature
[Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner.
Link to discussion: N/A — new feature
[Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again.
Regression Test Proposal
Precondition:
Test:
Do we agree 👍 or 👎
melvin-bot commentedon Sep 29, 2026
Triggered auto assignment to @mallenexpensify (
Awaiting Payment)melvin-bot commentedon Sep 29, 2026
Payment Summary
Resolving PRs:
Show receipt page count badge for split expenses #100361
Reviewer: @abzokhattab owed $175 via NewDot
Contributor: @ishpaul777 does not require payment (Contractor)
BugZero Checklist (@mallenexpensify)
mallenexpensify commentedon Oct 1, 2026
Payment Summary
Contributor+: @abzokhattab due $250 via NewDot
Paid 100% cuz, from @ishpaul777 's comment, it sounds like the bug pre-existed the PR. Comment/reopen if any disagrees