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
LHN - The draft message icon is not displayed, and the message is not preserved in the chat. #96092
👋 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.
⏱️ Ran out of time before I could finish. This usually means the task was too complex or I got stuck exploring. Please try again with a more specific request or post in #melvinbot-ai.
Classification: Frontend bug Causing PR: #93980 - "[No QA] Swap babel-loader + babel-plugin-react-compiler for OXC (Rust React Compiler)" by @roryabraham (High confidence) Related Issues: #95833 (Replace Webpack + Babel with Rsbuild + OXC for E/App)
Recommendation: REVERT
PR #93980 swaps the app-wide React Compiler from babel-plugin-react-compiler to OXC's Rust React Compiler port; a memoization discrepancy in that port breaks the debounced draft-save hook so reportDraftComment_ is never written to Onyx, which produces both symptoms (composer text not preserved + no LHN draft icon). Reverting restores the previous, working compiler with no source changes needed.
Assigned: @roryabraham (PR author), @chuckdries (approving reviewer) Labels: No changes. DeployBlockerCash is kept (App deploy is correctly blocked by this frontend regression); DeployBlocker was not present.
📋 Detailed Analysis
Evidence
The bug is a staging-only regression (not on production) affecting draft persistence for any chat — a broad, app-wide failure rather than a feature-specific one.
I diffed the entire draft read/write/display chain between production and staging and every relevant source file is byte-identical: ComposerWithSuggestions.tsx, useDebounce.ts, useDebouncedSaveDraft.ts, SilentCommentUpdater/index.tsx, ComposerProvider.tsx, saveReportDraftComment in actions/Report/index.ts, OptionRowLHNData.tsx, and SidebarUtils.ts. None of them changed in this deploy, and react-native-onyx is 3.0.86 on both refs (the 3.0.89 bump in Bump Onyx to 3.0.89 #93436 was reverted).
Yet drafts stopped persisting — meaning the regression is in something that transforms all of this code, not the code itself.
The PR description itself flags the fragility of the new pipeline: the OXC reactCompiler transform is a separate Rust reimplementation, and misconfiguration is "silently a no-op … with no build failure to catch it."
Verification
Affected write path: saveReportDraftComment → Onyx.merge(reportDraftComment_${reportID}, comment || null) (src/libs/actions/Report/index.ts:2969-2971), invoked via the debounced debouncedSaveComment in ComposerWithSuggestions.tsx:300-307, 569-573.
Affected read paths (both symptoms share the same Onyx key):
Composer restore: SilentCommentUpdater/index.tsx:26 and ComposerProvider.tsx:50 read reportDraftComment_${reportID}.
LHN indicator: OptionRowLHNData.tsx:125-126 computes hasDraftComment = !!draftComment from the same key.
Confirmed via gh pr view 93980 --json files that the PR modifies compiler/build config exclusively and no Composer|Draft|Report/index|SidebarUtils|useDebounce|LHN files.
Root Cause
The React Compiler auto-memoizes callbacks, effects, and derived values across the whole app. The draft save relies on useDebouncedSaveDraft → useDebounce, where useDebounce's useEffectcancels the pending debounced call whenever its func dependency changes identity (src/hooks/useDebounce.ts:28-36). Under the previous babel-plugin-react-compiler, these hook inputs were memoized to stable references so the trailing-edge debounce fired and wrote the draft. The OXC Rust React Compiler port memoizes differently, so the debounced saveReportDraftComment is repeatedly cancelled before DRAFT_SAVE_DEBOUNCE_TIME elapses and the reportDraftComment_ key is never written. Because both the composer restore and the LHN hasDraftComment indicator read that same never-written key, the typed message is lost on navigation and the draft icon never appears.
Activity
applause-bot commentedon Jul 14, 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/b7d63e1dd715401288d1ed1a78b9c7453944e19f0e577ac1fa9a7bac6f105d63
melvin-bot commentedon Jul 14, 2026
Triggered auto assignment to @madmax330 (
DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.melvin-bot commentedon Jul 14, 2026
💬 A slack conversation has been started in #expensify-open-source
github-actions commentedon Jul 14, 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:
roryabraham commentedon Jul 14, 2026
looking!
MelvinBot commentedon Jul 14, 2026
⏱️ Ran out of time before I could finish. This usually means the task was too complex or I got stuck exploring. Please try again with a more specific request or post in #melvinbot-ai.
Run details
MelvinBot commentedon Jul 14, 2026
🔍 Investigation Summary
Classification: Frontend bug
Causing PR: #93980 - "[No QA] Swap babel-loader + babel-plugin-react-compiler for OXC (Rust React Compiler)" by @roryabraham (High confidence)
Related Issues: #95833 (Replace Webpack + Babel with Rsbuild + OXC for E/App)
Recommendation: REVERT
PR #93980 swaps the app-wide React Compiler from
babel-plugin-react-compilerto OXC's Rust React Compiler port; a memoization discrepancy in that port breaks the debounced draft-save hook soreportDraftComment_is never written to Onyx, which produces both symptoms (composer text not preserved + no LHN draft icon). Reverting restores the previous, working compiler with no source changes needed.Assigned: @roryabraham (PR author), @chuckdries (approving reviewer)
Labels: No changes.
DeployBlockerCashis kept (App deploy is correctly blocked by this frontend regression);DeployBlockerwas not present.📋 Detailed Analysis
Evidence
productionandstagingand every relevant source file is byte-identical:ComposerWithSuggestions.tsx,useDebounce.ts,useDebouncedSaveDraft.ts,SilentCommentUpdater/index.tsx,ComposerProvider.tsx,saveReportDraftCommentinactions/Report/index.ts,OptionRowLHNData.tsx, andSidebarUtils.ts. None of them changed in this deploy, andreact-native-onyxis3.0.86on both refs (the 3.0.89 bump in Bump Onyx to 3.0.89 #93436 was reverted).babel.config.js,config/rsbuild/loaders/oxc-react-compiler-loader.mjs,config/rsbuild/rsbuild.common.ts,package.json, etc. — and touches zero draft/composer/LHN source files. This is exactly why the source diffs are clean but runtime behavior regressed.reactCompilertransform is a separate Rust reimplementation, and misconfiguration is "silently a no-op … with no build failure to catch it."Verification
saveReportDraftComment→Onyx.merge(reportDraftComment_${reportID}, comment || null)(src/libs/actions/Report/index.ts:2969-2971), invoked via the debounceddebouncedSaveCommentinComposerWithSuggestions.tsx:300-307, 569-573.SilentCommentUpdater/index.tsx:26andComposerProvider.tsx:50readreportDraftComment_${reportID}.OptionRowLHNData.tsx:125-126computeshasDraftComment = !!draftCommentfrom the same key.gh pr view 93980 --json filesthat the PR modifies compiler/build config exclusively and noComposer|Draft|Report/index|SidebarUtils|useDebounce|LHNfiles.Root Cause
The React Compiler auto-memoizes callbacks, effects, and derived values across the whole app. The draft save relies on
useDebouncedSaveDraft→useDebounce, whereuseDebounce'suseEffectcancels the pending debounced call whenever itsfuncdependency changes identity (src/hooks/useDebounce.ts:28-36). Under the previousbabel-plugin-react-compiler, these hook inputs were memoized to stable references so the trailing-edge debounce fired and wrote the draft. The OXC Rust React Compiler port memoizes differently, so the debouncedsaveReportDraftCommentis repeatedly cancelled beforeDRAFT_SAVE_DEBOUNCE_TIMEelapses and thereportDraftComment_key is never written. Because both the composer restore and the LHNhasDraftCommentindicator read that same never-written key, the typed message is lost on navigation and the draft icon never appears.m-natarajan commentedon Jul 14, 2026
Windows 10 / Chrome
Repro
bandicam.2026-07-14.17-01-23-738.mp4
m-natarajan commentedon Jul 15, 2026
Windows 10 / Chrome
v9.4.34-8
Issue is not reproducible
Repro96092Web.mp4
mitarachim commentedon Jul 15, 2026
Deploy Blocker #96158 was identified to be related to the PR #96115 that attempted to fix this issue.
mitarachim commentedon Jul 15, 2026
Deploy Blocker #96159 was identified to be related to the PR #96115 that attempted to fix this issue.
mitarachim commentedon Jul 15, 2026
Deploy Blocker #96161 was identified to be related to the PR #96115 that attempted to fix this issue.