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-23] [$250] chat - Unexpected error still shown on "Reply in thread" for legitimate moved system messages #99653
The merged fix (Expensify/App#95979) for #95866 only closed the narrow repro — creating a report from a draft expense. Moved system messages that legitimately appear (e.g. moving an expense between already-submitted reports) still offer "Reply in thread." Tapping it kicks off a thread-creation call against an action the server never adopted, which fails and renders "Unexpected error creating this chat. Please try again later."
So the underlying user-visible error can still occur outside the one path that was patched.
Proposed FE fix — gate moved system messages out of the thread UI
Gate MOVED / MOVED_TRANSACTION out of the thread UI the same way CREATED already is, so the doomed thread-creation call is never made:
Two approaches (both raised on the original proposals):
Blanket: add MOVED + MOVED_TRANSACTION to THREAD_DISABLED. Simplest, but disables threading on every moved action.
Guarded: disable only when the action isn't already threaded (e.g. !reportAction?.childVisibleActionCount), preserving any moved actions users have legitimately threaded. Slightly more code, safer.
Scope: small, isolated to ReportUtils.ts + a unit test.
Scope note
This FE change is a defensive fix that stops the user-facing error. There's also a separate backend root-cause angle (why the moved action can't be threaded at all) that's being tracked internally and is not App-contributor work — so a frontend volunteer can proceed on the above independently.
Please mark it as "Ready for review" when it is ready.
What I did: Gated MOVED / MOVEDTRANSACTION system messages out of the thread UI in shouldDisableThread, so tapping "Reply in thread" no longer fires the doomed thread-creation call that produced "Unexpected error creating this chat. Please try again later."
I used the guarded approach from the proposal (safer of the two): threading is disabled only when the moved action has no threaded child (!reportAction?.childVisibleActionCount), mirroring how deleted/archived actions are already handled — so any moved actions users have legitimately threaded keep working.
Changes & tests
src/libs/ReportUtils.ts — add isMovedSystemMessage && !childVisibleActionCount to shouldDisableThread.
tests/unit/ReportUtilsTest.ts — 4 new cases covering both action types, disabled when unthreaded / enabled when already threaded.
AI tests run locally:
npm test -- tests/unit/ReportUtilsTest.ts -t "shouldDisableThread" → pass (17 tests)
npm run typecheck → pass
eslint on changed files → 0 errors
Live web verification couldn't be completed — the test session rendered a blank page (a test-infra issue, not an App bug), so I wasn't able to reproduce the moved-message flow in the browser. The unit tests directly cover the gating logic; manual/QA steps are in the PR for a human to confirm.
📣 @NEXAITECHAU! 📣
Hey, it seems we don’t have your contributor details yet! You'll only have to do this once, and this is how we'll hire you on Upwork.
Please follow these steps:
Get the email address used to login to your Expensify account. If you don't already have an Expensify account, create one here. If you have multiple accounts (e.g. one for testing), please use your main account email.
Get the link to your Upwork profile. It's necessary because we only pay via Upwork. You can access it by logging in, and then clicking on your name. It'll look like this. If you don't already have an account, sign up for one here.
Copy the format below and paste it in a comment on this issue. Replace the placeholder text with your actual details.
Format:
Contributor details
Your Expensify account email: <REPLACE EMAIL HERE>
Upwork Profile Link: <REPLACE LINK HERE>
changed the title [-][$250] chat - Unexpected error still shown on "Reply in thread" for legitimate moved system messages[/-][+][Due for payment 2026-09-15] [$250] chat - Unexpected error still shown on "Reply in thread" for legitimate moved system messages[/+]on Sep 8, 2026
changed the title [-][Due for payment 2026-09-15] [$250] chat - Unexpected error still shown on "Reply in thread" for legitimate moved system messages[/-][+][Due for payment 2026-09-23] [$250] chat - Unexpected error still shown on "Reply in thread" for legitimate moved system messages[/+]on Sep 16, 2026
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.4.80-0 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-09-23. 🎊
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]
Activity
mkhutornyi commentedon Aug 28, 2026
@MelvinBot implement this
MelvinBot commentedon Aug 28, 2026
🤖 Draft PR created: #99721
Please mark it as "Ready for review" when it is ready.
What I did: Gated
MOVED/MOVEDTRANSACTIONsystem messages out of the thread UI inshouldDisableThread, so tapping "Reply in thread" no longer fires the doomed thread-creation call that produced "Unexpected error creating this chat. Please try again later."I used the guarded approach from the proposal (safer of the two): threading is disabled only when the moved action has no threaded child (
!reportAction?.childVisibleActionCount), mirroring how deleted/archived actions are already handled — so any moved actions users have legitimately threaded keep working.Changes & tests
src/libs/ReportUtils.ts— addisMovedSystemMessage && !childVisibleActionCounttoshouldDisableThread.tests/unit/ReportUtilsTest.ts— 4 new cases covering both action types, disabled when unthreaded / enabled when already threaded.AI tests run locally:
npm test -- tests/unit/ReportUtilsTest.ts -t "shouldDisableThread"→ pass (17 tests)npm run typecheck→ passeslinton changed files → 0 errorsLive web verification couldn't be completed — the test session rendered a blank page (a test-infra issue, not an App bug), so I wasn't able to reproduce the moved-message flow in the browser. The unit tests directly cover the gating logic; manual/QA steps are in the PR for a human to confirm.
view run
melvin-bot commentedon Aug 30, 2026
📣 @NEXAITECHAU! 📣
Hey, it seems we don’t have your contributor details yet! You'll only have to do this once, and this is how we'll hire you on Upwork.
Please follow these steps:
Format:
melvin-bot commentedon Sep 6, 2026
Unable to auto-create job on Upwork. The BZ team member should create it manually for this issue.
melvin-bot commentedon Sep 6, 2026
Triggered auto assignment to @marcochavezf, see https://stackoverflow.com/c/expensify/questions/7972 for more details.
[-][$250] chat - Unexpected error still shown on "Reply in thread" for legitimate moved system messages[/-][+][Due for payment 2026-09-15] [$250] chat - Unexpected error still shown on "Reply in thread" for legitimate moved system messages[/+]8 remaining items
melvin-bot commentedon Sep 14, 2026
Triggered auto assignment to @mallenexpensify (
Awaiting Payment)melvin-bot commentedon Sep 14, 2026
Payment Summary
Resolving PRs:
Do not optimistically create the moved-expense system message when the destination report is a draft #99721
Reviewer: @mkhutornyi owed $250 via NewDot
BugZero Checklist (@mallenexpensify)
[-][Due for payment 2026-09-15] [$250] chat - Unexpected error still shown on "Reply in thread" for legitimate moved system messages[/-][+][Due for payment 2026-09-23] [$250] chat - Unexpected error still shown on "Reply in thread" for legitimate moved system messages[/+]melvin-bot commentedon Sep 16, 2026
@mkhutornyi @mallenexpensify
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.4.80-0 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-09-23. 🎊
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]
melvin-bot commentedon Sep 17, 2026
@mkhutornyi Whoops! This issue is 2 days overdue. Let's get this updated quick!
mkhutornyi commentedon Sep 17, 2026
This is ready for payment. 2nd PR is just doc updates.
mallenexpensify commentedon Sep 18, 2026
Payment Summary
Contributor+: @mkhutornyi due $250 via NewDot
mallenexpensify commentedon Sep 29, 2026
@marcochavezf @mkhutornyi do either of you know what's up with
It spun off this issue, unsure what to do with it
trjExpensify commentedon Oct 1, 2026
approved $250 for @mkhutornyi