Skip to content

[Due for payment 2026-06-29] [Due for payment 2026-06-26] [$500] Web – Uh-oh crash after saving expense description from Search (React #185) #91584

Description

@mountiny

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Version Number: Web production build (e.g. 9.3.77-3 class; exact build TBD at repro)
Reproducible in staging?: TBD
Reproducible in production?: Yes (confirmed via internal logs + session replay; details not in this issue)
If this was caught during regression testing, add the test name, ID and link from BrowserStack:
Email or phone of affected tester (no customers): N/A — customer report, redacted
Logs: https://stackoverflow.com/c/expensify/questions/4856 (internal VL query available to assignee)
Expensify/Expensify Issue URL:
Issue reported by: Internal investigation
Slack conversation (hyperlinked to channel name):

Related (observability, not root fix): #91407, #91405

Action Performed

  1. Go to Search and open an expense from the results (search money-request report view).
  2. Open Description edit for a submit expense (RHP): route pattern edit/submit/description/:transactionID/:reportID.
  3. Change the description text and tap Save.
  4. App attempts to navigate back to the search expense view: route pattern search/view/:reportID.

Expected Result

Description saves successfully; user returns to the search expense view with the report UI intact.

Actual Result

Full-page GenericErrorPage (“Uh-oh, something went wrong!”) — top-level ErrorBoundary in App.tsx (errorMessage="NewExpensify crash caught by error boundary").

Workaround

Refresh the page (or sign out and back in). The description change may or may not have persisted.

Platforms

Select the officially supported platforms where the issue was reproduced:

  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome / Safari

Screenshots/Videos

Add screenshots if available; no customer session links in this issue.


Technical details (for implementers)

Error

  • React error #185Maximum update depth exceeded (infinite re-render loop).
  • Logged client-side as: NewExpensify crash caught by error boundary - Minified React error #185; visit https://react.dev/errors/185 ...
  • Sentry: Web render errors caught by the boundary were not appearing as Sentry error events prior to [No QA] Report caught render errors to Sentry from the web ErrorBoundary #91407 (boundary only called Log.alert). Do not rely on Sentry alone to validate this bug until that ships.

Component stack (deepest → root, from production web bundle)

Abbreviated stack at time of crash:

ViewHolderCollection
  → RecyclerViewComponent (FlashList)
  → components_FlashList / FlashList_InvertedFlashList
  → ReportActionsList / report_ReportActionsView / inbox_ReportActionsList
  → ConciergeDraftProvider / AgentZeroStatusProvider
  → components_OfflineWithFeedback
  → ReportNotFoundGuard / ScreenWrapper / WithNavigationFallback
  → inbox_ReactionListWrapper / WideRHPOverlayWrapper
  → ReportActionEditMessageContextProvider
  → ReportScreenEditMessageProvider
  → inbox_ReportScreen / RHPReportScreen
  → Navigation (EnsureSingleNavigator / SceneView)

Suspected root cause

Save → navigate back flow:

Strong suspect: ReportActionEditMessageContextProvider performs setState during render when bridging Onyx drafts:

// ReportActionEditMessageContext.tsx (simplified)
if (activeDraftEditResolution !== null) {
    if (editingState === CONST.REPORT_ACTION_EDIT_MESSAGE_STATE.OFF) {
        setEditingState(CONST.REPORT_ACTION_EDIT_MESSAGE_STATE.EDITING); // during render
    }
    syncComposerDraftFromPersistedOnyxDraft(...); // also setState during render
}
if (editingReportID == null && editingState !== CONST.REPORT_ACTION_EDIT_MESSAGE_STATE.OFF) {
    stopEditing(); // setState during render
}

After saving description and navigating back, Onyx draft / report-action updates may re-enter this path on every render → React #185 → error boundary.

Suggested fix direction: Move draft sync / setEditingState / stopEditing into useEffect (or derive state without setState-in-render), with stable dependencies on activeDraftEditResolution fields.

Contributor repro (no customer data needed)

  1. Search → open any submit expense from search results.
  2. Edit Description → change text → Save.
  3. Confirm landing on search/view/:reportID without the generic error page.
  4. If flaky: try with an active report-action draft / edit-message state, or repeat save immediately after opening the expense RHP.

Out of scope

View all open jobs on GitHub

Upwork Automation - Do Not Edit
Issue OwnerCurrent Issue Owner: @ZhenjaHorbach

Activity

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

Metadata

Metadata

Labels

Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributor

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions