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-06-16] Expense - Amount field is 0.00 by default #92005
Version Number: 9.3.88-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:#87920 Email or phone of affected tester (no customers):sdjsodnjiodsjsoinj1@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:
Run Onyx.merge('betas', ['newManualExpenseFlow']); in console.
Go to staging.new.expensify.com
Go to workspace chat.
Click + > Create expense > Manual.
Expected Result:
Amount field will be empty by default.
Actual Result:
Amount field is 0.00 by default.
User will need to clear the input to enter amount.
👋 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.
Please re-state the problem that we are trying to solve in this issue.
In the new manual expense flow (newManualExpenseFlow beta), starting a manual expense from a workspace chat composer (+ → Create expense → Manual) renders the inline Amount field pre-filled with 0.00 instead of leaving it empty. The user must clear the input before they can type a real amount.
The behavior was introduced by PR #87920 (merged 2026-05-13), which refactored the manual expense flow to render the confirmation page inline and added an "empty by default" rule for the amount field. The rule fires off the wrong state and gets locked in by the input component.
What is the root cause of that problem?
Two-part race that locks "0.00" into the visible input.
Part 1 — empty-amount predicate flips false → true after first render. In AmountField.tsx:115-116 the field is empty only when:
When the user picks + → Create expense from the workspace chat composer (AttachmentPickerWithMenuItems.tsx:239), startMoneyRequest(SUBMIT, reportID, draftTransactionIDs) clears the optimistic draft and navigates to IOURequestStartPage. With the beta on, the Manual tab renders IOURequestStepConfirmation directly (IOURequestStartPage.tsx:248-256). The transaction's iouRequestType is set to MANUAL later, asynchronously, by useResetIOUType's useFocusEffect calling initMoneyRequest (useResetIOUType.ts:89-105).
On the first render(s), transactionSlice?.iouRequestType is undefined, so shouldShowEmptyAmount === false and transactionAmount = convertToFrontendAmountAsString(0, 2) = "0.00".
Part 2 — NumberWithSymbolForm ignores subsequent value prop changes.NumberWithSymbolForm.tsx:210 seeds internal state from the prop exactly once:
const[currentNumber,setCurrentNumber]=useState(typeofnumber==='string' ? number : '');
There is no useEffect that syncs currentNumber when the value prop later changes. Once Onyx writes iouRequestType: MANUAL and AmountField re-renders with transactionAmount = '', the rendered TextInput value={formattedNumber} (line 493) is derived from the now-stale currentNumber = "0.00", so the field stays at 0.00.
The FAB flow (ExpenseMenuItem.tsx:34) hits the same logic and is also at risk; the workspace-chat path is the one Applause caught.
What changes do you think we should make in order to solve the problem?
Fix Part 1 at the source so the input never renders 0.00 on first paint. The predicate currently treats "iouRequestType not yet MANUAL" as "show the formatted amount," but for the new manual flow it should treat the absence of a user-set amount as empty regardless of whether iouRequestType has been populated yet.
In AmountField.tsx:115, relax the guard to no longer require iouRequestType === MANUAL — the field is only mounted in the new manual flow branch when isNewManualExpenseFlowEnabled && !isAmountFieldDisabled (lines 276 onward), and isAmountFieldDisabled already excludes distance/time. The scan flow programmatically sets the amount and toggles isAmountSet, so !isAmountSet is sufficient:
This also matches the comment on lines 111-114 which describes the intent as "amount field starts empty… until the user explicitly sets an amount."
As a defense-in-depth, also fix Part 2 by adding a useEffect in NumberWithSymbolForm that syncs currentNumber when the value prop changes and the input is not focused (avoid clobbering the user's typing). That prevents this same class of bug from recurring elsewhere.
What alternative solutions did you explore? (Optional)
Synchronously initialize the draft. Call initMoneyRequest before navigating in startMoneyRequest so iouRequestType: MANUAL is on the draft before AmountField mounts. More invasive and risks breaking the existing tab-driven useResetIOUType flow that depends on transitioning from "no type" to a chosen type.
Guard the AmountField render until transaction?.iouRequestType is set. Hides the issue but introduces a visible loading flash and doesn't address the NumberWithSymbolForm desync.
#90681 — "Unable to submit expense with 0.00 to self DM when created from FAB" (same PR, related amount-validation logic)
#90648 — "Confirm page loads infinitely after switching from Scan to Manual tab" (same PR)
#90652 — "Manual tab shows scan confirm page after uploading receipt on Scan and returning to Manual" (same PR)
Next Steps for Contributor+ team: To accept:@MelvinBot implement [this](https://github.com/Expensify/App/issues/92005) to create a draft PR. To refine:@MelvinBot <your feedback> To reject: Explain why you are rejecting Melvin's proposal.
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.4.0-7 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
@dukenv0307 The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]. If no checklist is needed for this issue, you can click: [no checklist button]
[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
Link to the comment on the Issue: 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:
[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.
[BugZero Assignee] Create a GH issue for creating/updating the regression test once above steps have been agreed upon.
Activity
applause-bot commentedon May 28, 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/0dcd8d627aa0a82115b3dfe8f22ca7f4d180d9c8502f6d3df71b6cfd736d62f8
melvin-bot commentedon May 28, 2026
@puneetlath recently merged #87920, but they are OOO right now, so I'll auto-assign someone else.
melvin-bot commentedon May 28, 2026
Triggered auto assignment to @MonilBhavsar (
DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.melvin-bot commentedon May 28, 2026
💬 A slack conversation has been started in #expensify-open-source
github-actions commentedon May 28, 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 May 28, 2026
Proposal
Please re-state the problem that we are trying to solve in this issue.
In the new manual expense flow (
newManualExpenseFlowbeta), starting a manual expense from a workspace chat composer (+ → Create expense → Manual) renders the inlineAmountfield pre-filled with0.00instead of leaving it empty. The user must clear the input before they can type a real amount.The behavior was introduced by PR #87920 (merged 2026-05-13), which refactored the manual expense flow to render the confirmation page inline and added an "empty by default" rule for the amount field. The rule fires off the wrong state and gets locked in by the input component.
What is the root cause of that problem?
Two-part race that locks "0.00" into the visible input.
Part 1 — empty-amount predicate flips false → true after first render. In
AmountField.tsx:115-116the field is empty only when:When the user picks
+ → Create expensefrom the workspace chat composer (AttachmentPickerWithMenuItems.tsx:239),startMoneyRequest(SUBMIT, reportID, draftTransactionIDs)clears the optimistic draft and navigates toIOURequestStartPage. With the beta on, the Manual tab rendersIOURequestStepConfirmationdirectly (IOURequestStartPage.tsx:248-256). The transaction'siouRequestTypeis set toMANUALlater, asynchronously, byuseResetIOUType'suseFocusEffectcallinginitMoneyRequest(useResetIOUType.ts:89-105).On the first render(s),
transactionSlice?.iouRequestTypeisundefined, soshouldShowEmptyAmount === falseandtransactionAmount = convertToFrontendAmountAsString(0, 2) = "0.00".Part 2 —
NumberWithSymbolFormignores subsequentvalueprop changes.NumberWithSymbolForm.tsx:210seeds internal state from the prop exactly once:There is no
useEffectthat syncscurrentNumberwhen thevalueprop later changes. Once Onyx writesiouRequestType: MANUALandAmountFieldre-renders withtransactionAmount = '', the renderedTextInput value={formattedNumber}(line 493) is derived from the now-stalecurrentNumber = "0.00", so the field stays at0.00.The FAB flow (
ExpenseMenuItem.tsx:34) hits the same logic and is also at risk; the workspace-chat path is the one Applause caught.What changes do you think we should make in order to solve the problem?
Fix Part 1 at the source so the input never renders
0.00on first paint. The predicate currently treats "iouRequestType not yet MANUAL" as "show the formatted amount," but for the new manual flow it should treat the absence of a user-set amount as empty regardless of whetheriouRequestTypehas been populated yet.In
AmountField.tsx:115, relax the guard to no longer requireiouRequestType === MANUAL— the field is only mounted in the new manual flow branch whenisNewManualExpenseFlowEnabled && !isAmountFieldDisabled(lines 276 onward), andisAmountFieldDisabledalready excludes distance/time. The scan flow programmatically sets the amount and togglesisAmountSet, so!isAmountSetis sufficient:This also matches the comment on lines 111-114 which describes the intent as "amount field starts empty… until the user explicitly sets an amount."
As a defense-in-depth, also fix Part 2 by adding a
useEffectinNumberWithSymbolFormthat syncscurrentNumberwhen thevalueprop changes and the input is not focused (avoid clobbering the user's typing). That prevents this same class of bug from recurring elsewhere.What alternative solutions did you explore? (Optional)
initMoneyRequestbefore navigating instartMoneyRequestsoiouRequestType: MANUALis on the draft beforeAmountFieldmounts. More invasive and risks breaking the existing tab-drivenuseResetIOUTypeflow that depends on transitioning from "no type" to a chosen type.transaction?.iouRequestTypeis set. Hides the issue but introduces a visible loading flash and doesn't address theNumberWithSymbolFormdesync.Likely related open issues from a quick scan
Next Steps for Contributor+ team:
To accept:
@MelvinBot implement [this](https://github.com/Expensify/App/issues/92005)to create a draft PR.To refine:
@MelvinBot <your feedback>To reject: Explain why you are rejecting Melvin's proposal.
20 remaining items
melvin-bot commentedon Jun 9, 2026
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.4.0-7 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
If no regressions arise, payment will be issued on 2026-06-16. 🎊
For reference, here are some details about the assignees on this issue:
melvin-bot commentedon Jun 9, 2026
@dukenv0307 The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]. If no checklist is needed for this issue, you can click: [no checklist button]
dukenv0307 commentedon Jun 10, 2026
BugZero 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
Link to the comment on the Issue: 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:
[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.
[BugZero Assignee] Create a GH issue for creating/updating the regression test once above steps have been agreed upon.
Link to issue: https://github.com/Expensify/Expensify/issues/650116
Regression Test Proposal
Precondition:
Test:
Do we agree 👍 or 👎
Zapier Logs
Run ID: 00040eee-02e8-a373-bbad-0f50db0b9114MonilBhavsar commentedon Jun 10, 2026
@dukenv0307 can you add step 5. to repeat 3. and 4. couple of times
dukenv0307 commentedon Jun 11, 2026
Updated
dukenv0307 commentedon Jun 18, 2026
@mallenexpensify can you please handle payment for this issue? Thanks
mallenexpensify commentedon Jun 18, 2026
Payment Summary
Contributor+: @dukenv0307 due $250 via NewDot
^ Test case created. Thx
quinthar commentedon Jun 29, 2026
Approved $250 to @dukenv0307