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-11-05] [$175] Green loading button&Submit button are shown together briefly after dismissing download modal #105206
Version Number: 9.5.24-2 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:#104534 Email or phone of affected tester (no customers):djosdionjonijsdioj@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:
Complete onboarding with Submit expenses to my employer.
Go to staging.new.expensify.com
Go to workspace chat.
Create an expense.
Open the expense.
Click Submit dropdown button.
Click Submit via PDF.
Quickly click outside Generate PDF modal to dismiss it.
Expected Result:
Green loading button will disappear and be replaced by Submit button.
Actual Result:
Green loading button and Submit button are shown together briefly after dismissing download modal.
👋 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.
Recommendation: Revert. It's a refactor that wasn't meant to change behavior, and it was the last App PR merged in the Deploy Checklist: New Expensify 2026-10-27, so the revert should be clean.
Root cause: Before this PR, cancelling Submit via PDF stopped the green "Submitting" animation as soon as you clicked to dismiss. That happened while the modal was still fading out. Now the cleanup waits until the modal has fully hidden. The header then replaces AnimatedSubmitButton with the Submit dropdown on a clear screen. Meanwhile, the old spinner's Reanimated exiting animation keeps it visible for about 250ms next to the new button.
Fix-forward alternative: In FileDownloadModalWrapper.tsx:25-35, call resolveModal({action: closeActionRef.current}) inside handleClose. Keep closeModal() in onModalHide. resolveModal settles the show promise without taking the modal off the stack. The wrapper already receives it but never calls it. This brings back the old dismiss-time timing.
Investigation details
Why this PR
It's the only PR in the 9.5.24-2 checklist that touches the Submit via PDF dismiss flow or SubmitPrimaryAction.tsx.
The spinner in AnimatedSubmitButton has an exiting keyframe that runs for 200–250ms (AnimatedSubmitButton/index.tsx:161-178). Reanimated keeps it on screen after unmount while the new dropdown is already showing. Before the PR, the fading modal overlay hid this overlap.
Caveat: The overlap comes from a timing problem in AnimatedSubmitButton that existed before this PR. This PR only made it visible. Removing it completely would mean skipping the exit animation when the animation is cancelled.
Demoting is defensible: The glitch is cosmetic, lasts about 250ms, and only appears in a new feature that isn't in production. The retract still completes. Reverting or fixing is still cheap.
In src/components/Modal/Global/FileDownloadModalWrapper.tsx, add an optional shouldResolveOnDismiss prop (default false). When it is true, call resolveModal({action: closeActionRef.current}) at the end of handleClose, after setIsVisible(false). Keep closeModal in handleModalHide so the modal still leaves the stack once it has finished hiding.
In src/components/ReportPDFDownloadModal.tsx, pass shouldResolveOnDismiss to FileDownloadModalWrapper.
changed the title [-][$175] Green loading button&Submit button are shown together briefly after dismissing download modal[/-][+][Due for payment 2026-11-05] [$175] Green loading button&Submit button are shown together briefly after dismissing download modal[/+]on Oct 29, 2026
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.5.24-8 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-11-05. 🎊
The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the Contributor+ 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.
[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.
Regression Test Proposal
Precondition:
Complete onboarding with Submit expenses to my employer.
Test:
Go to workspace chat.
Create an expense.
Open the expense.
Click Submit dropdown button.
Click Submit via PDF.
Quickly click outside Generate PDF modal to dismiss it.
Verify that Green loading button will disappear and be replaced by Submit button.
Activity
melvin-bot commentedon Oct 27, 2026
You have been assigned to this deploy blocker because you recently merged this PR: #104534
applause-bot commentedon Oct 27, 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/e2a3831741f079d9d81fd7e855d5629c54adc266bb540bb784b2c61794dc87ce
https://platform.applause.com/services/links/v1/external/b610f75d21334d1733bbc9ec066a9301008697f2d582821c1a806a3a0703f1a4
melvin-bot commentedon Oct 27, 2026
@roryabraham @daledah you have been assigned to this deploy blocker because you reviewed the offending PR: #104534
melvin-bot commentedon Oct 27, 2026
💬 A slack conversation has been started in #expensify-open-source
github-actions commentedon Oct 27, 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 Oct 27, 2026
Deploy Blocker Analysis
Causing PR (high confidence): Decouple the file download modal from report and Expensify Card logic
Recommendation: Revert. It's a refactor that wasn't meant to change behavior, and it was the last App PR merged in the Deploy Checklist: New Expensify 2026-10-27, so the revert should be clean.
Root cause: Before this PR, cancelling Submit via PDF stopped the green "Submitting" animation as soon as you clicked to dismiss. That happened while the modal was still fading out. Now the cleanup waits until the modal has fully hidden. The header then replaces
AnimatedSubmitButtonwith the Submit dropdown on a clear screen. Meanwhile, the old spinner's Reanimatedexitinganimation keeps it visible for about 250ms next to the new button.Fix-forward alternative: In
FileDownloadModalWrapper.tsx:25-35, callresolveModal({action: closeActionRef.current})insidehandleClose. KeepcloseModal()inonModalHide.resolveModalsettles the show promise without taking the modal off the stack. The wrapper already receives it but never calls it. This brings back the old dismiss-time timing.Investigation details
Why this PR
SubmitPrimaryAction.tsx.Buttonloading, but only when a caller opts in, andAnimatedSubmitButtondoesn't.stopAnimation()"now run after the modal finishes hiding, not at the moment the user dismisses it."Mechanism (App
13567c6)handleClosecalledonCancelbeforeonClose(ReportPDFDownloadModal.tsx:62-66).onCancelranstopAnimation()andretractReport()right away (SubmitPrimaryAction.tsx:187-191).handleCloseonly hides the modal.closeModal()runs fromonModalHide(FileDownloadModalWrapper.tsx:39-45). Then the.thenrunsstopAnimation()andretractReport()(SubmitPrimaryAction.tsx:188-197).stopAnimation()setsisSubmittingAnimationRunningto false (usePaymentAnimations.ts:10-14), so the header switches toButtonWithDropdownMenu(SubmitPrimaryAction.tsx:224-261).AnimatedSubmitButtonhas anexitingkeyframe that runs for 200–250ms (AnimatedSubmitButton/index.tsx:161-178). Reanimated keeps it on screen after unmount while the new dropdown is already showing. Before the PR, the fading modal overlay hid this overlap.Caveat: The overlap comes from a timing problem in
AnimatedSubmitButtonthat existed before this PR. This PR only made it visible. Removing it completely would mean skipping the exit animation when the animation is cancelled.Demoting is defensible: The glitch is cosmetic, lasts about 250ms, and only appears in a new feature that isn't in production. The retract still completes. Reverting or fixing is still cheap.
view run
daledah commentedon Oct 28, 2026
Checking now
daledah commentedon Oct 28, 2026
@MelvinBot please create a PR to fix this issue:
src/components/Modal/Global/FileDownloadModalWrapper.tsx, add an optionalshouldResolveOnDismissprop (defaultfalse). When it is true, callresolveModal({action: closeActionRef.current})at the end ofhandleClose, aftersetIsVisible(false). KeepcloseModalinhandleModalHideso the modal still leaves the stack once it has finished hiding.src/components/ReportPDFDownloadModal.tsx, passshouldResolveOnDismisstoFileDownloadModalWrapper.ExpensifyCardStatementPDFDownloadModalunchanged5 remaining items
roryabraham commentedon Oct 28, 2026
Requested retest of the AdHoc build for my fix: https://expensify.slack.com/archives/C09V78U42D8/p1793223509531819
roryabraham commentedon Oct 28, 2026
opened #105297 for review
m-natarajan commentedon Oct 28, 2026
Windows 11 / Chrome, Google Pixel 7a / Android 17, iPhone 15 Pro / iOS 27.0.1, v9.5.24-8
The green loading button is no longer displayed.
Expensify_105206_Retest_iOS.mp4
Expensify_105206_Retest_Android.mp4
Expensify_105206_Retest_Web.mp4
[-][$175] Green loading button&Submit button are shown together briefly after dismissing download modal[/-][+][Due for payment 2026-11-05] [$175] Green loading button&Submit button are shown together briefly after dismissing download modal[/+]melvin-bot commentedon Oct 29, 2026
@daledah
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.5.24-8 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-11-05. 🎊
The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the Contributor+ 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]
mkhutornyi commentedon Oct 30, 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: Decouple the file download modal from report and Expensify Card logic #104534 (comment)
Link to the comment on the Issue:
[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.
Regression Test Proposal
Precondition:
Complete onboarding with Submit expenses to my employer.
Test:
Do we agree 👍 or 👎