Skip to content

[Due for payment 2026-08-07] [$250] Chat view - Clicking nothing for now shows an error when screen size is small #95719

Closed

Description

@applause-bot

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: 9.4.32-0
Reproducible in staging?: Yes
Reproducible in production?: No
If this was caught during regression testing, add the test name, ID and link from BrowserStack: https://test-management.browserstack.com/projects/2219752/test-runs/63957099/folder/13176877/41237359/1554721739
Email or phone of affected tester (no customers): emady.syed1234+nu1@gmail.com
Issue reported by: Applause Internal Team
Bug source: Regression TC Execution
Device used: Windows 11 / Chrome
App Component: Other

Action Performed:

Precondition : Resize the browser to atleast half of the sceen

  1. Open staging.new.expensify
  2. Go to own chat
  3. Submit an expense
  4. Click on nothing for now

Expected Result:

It should not show any error

Actual Result:

Error appears when click on nothing for now when screen size is small

Workaround:

Unknown

Platforms:

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

Screenshots/Videos

Bug7203839_1783605993169.Recording__972.mp4

View all open jobs on GitHub

Applause Internal Information
Exported by: Svetlana Lazutkina
Bug ID: 7203839

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

Activity

  1. added
    BugSomething is broken. Auto assigns a BugZero manager.
    on Jul 9, 2026
  2. applause-bot commented on Jul 9, 2026

    @applause-bot
    Author

    While Applause doesn't embed attachments for this bug, here are the links for quick view:
    https://platform.applause.com/services/links/v1/external/806e6dea0f9fff4cd0d878956f3be4ded356367a5624ce63cb258c4587fc5482

  3. melvin-bot commented on Jul 9, 2026

    @melvin-bot

    Triggered auto assignment to @NicolasBonet (DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.

  4. melvin-bot commented on Jul 9, 2026

    @melvin-bot

    💬 A slack conversation has been started in #expensify-open-source

  5. github-actions commented on Jul 9, 2026

    @github-actions
    Contributor

    👋 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:

    1. Identify the pull request that introduced this issue and revert it.
    2. Find someone who can quickly fix the issue.
    3. Fix the issue yourself.
  6. MelvinBot commented on Jul 9, 2026

    @MelvinBot
    Contributor

    ⚠️ Preliminary analysis (low confidence) — I could not capture the exact error or reproduce the crash, so treat this as a starting point, not a conclusion.

    What "Nothing for now" does: It is the only track-expense whisper button whose onPress calls dismissTrackExpenseActionableWhisper (the other three navigate to the participant selector). That function is layout-agnostic — it just optimistically merges resolution: 'nothing' onto the report action and fires the API write (Report/index.ts:6001). Once resolved, the whole whisper action is hidden by shouldReportActionBeVisible.

    So the error is almost certainly not in the dismiss call itself, but in the re-render/list re-computation triggered when the whisper disappears — and it only surfaces on a small/narrow layout. I could not find a narrow-layout-gated throw statically, and a correct click on the button did not crash on latest main (see below), so I can't confirm the mechanism.

    To move this forward, the single most useful thing is the exact red-box/console error + stack frame from the repro video (e.g. Cannot read properties of undefined (reading …) and the component name). That will immediately point to the throwing component. This is a client-side JS error, so it won't be in server logs.

    Investigation details
    • Confirmed: dismissTrackExpenseActionableWhisper has no responsive-layout dependency; after it resolves the whisper, the action is removed from the list. The only narrow-layout branch in the direct render path is isEditingInline in ChatMessageContent, which does not touch track-expense whispers.
    • Could not reproduce on main (HEAD 5fadbf3): In a narrow (~800px) browser, submitting a self-DM expense and clicking "Nothing for now" fired DismissActionableWhisper (HTTP 200) and dismissed the whisper with no visible error. (The test tooling did misfire one click onto the emoji picker, but that is an accessibility-ref artifact, not the reported bug.) This build is newer than the reported staging build 9.4.32-0, so the offending change may already be reverted/fixed, or the crash needs specific state (e.g. the track-flows beta, which enables the extra "Categorize"/"Share" options) not present in the test account.
    • Best candidates for the throw, if it is a re-render crash gated on narrow layout: a sibling consumer of the same action that recomputes when it disappears — e.g. OptionRowLHNData.tsx:106 (reads getOriginalMessage(lastAction)?.transactionID for the resolved whisper) or the tracked-expense preview/thread-divider recompute in ReportActionsList.

    Suggested next steps for the assignee:

    1. Grab the exact console error + stack from the repro video / a fresh repro with DevTools open.
    2. Confirm whether it still reproduces on the latest staging build — I could not reproduce a crash on current main.
    3. If it reproduces, the offending PR is likely one in this deploy that touches the track-expense whisper render path or a component that re-renders when the whisper resolves.

    Next Steps: Reply with @MelvinBot <the exact error text from the video> and I'll pinpoint the throwing component, or @MelvinBot <your feedback> to refine this analysis.

  7. NicolasBonet commented on Jul 9, 2026

    @NicolasBonet
    Contributor

    I tried to reproduce this and got nothing:

    CleanShot.2026-07-09.at.09.52.00.mp4

    Please try to reproduce it again. Asking for a re-test.

  8. m-natarajan commented on Jul 9, 2026

    @m-natarajan

    Able to reproduce in latest staging.
    Reproduction steps:

    1. Open staging.new.expensify
    2. Go to own chat
    3. Submit an expense
    4. Click on nothing for now
    5. Then reduce the window size.
    Recording.5986.mp4
  9. NicolasBonet commented on Jul 9, 2026

    @NicolasBonet
    Contributor

    @MelvinBot please assign someone else, I have two other blockers, I cannot take care of this one which is unrelated with my changes.

  10. MelvinBot commented on Jul 9, 2026

    @MelvinBot
    Contributor

    🔍 Investigation Summary

    Classification: Frontend bug
    Causing PR: #95045 - "Open linked message at top - 3" by @VickyStash (Medium-High confidence)
    Related Issues: None

    Recommendation: REVERT

    This PR reworked the report-actions FlashList mount/scroll positioning to drive off initialScrollIndex + initialScrollIndexParams (tied to windowHeight) and shipped a new FlashList patch, and it is the only newly-deployed PR in this release that touches the exact render path where the crash surfaces (report actions list re-layout after the whisper is dismissed and the window is resized). Reverting is clean since it is a self-contained scroll/render change.

    Assigned: @VickyStash (PR author), @aimane-chnaif and @JS00001 (approving reviewers)
    Labels: No change — DeployBlockerCash kept (frontend bug, App deploy is blocked). No DeployBlocker present, so nothing removed.

    📋 Detailed Analysis

    Evidence

    Verification

    • Affected render path: src/pages/inbox/report/ReportActionsList.tsx and src/hooks/useReportActionsScroll.ts (the self-DM chat whisper renders in ReportActionsList, not MoneyRequestReportView).
    • Confirmed Open linked message at top - 3 #95045 modifies exactly these files (gh pr view 95045 --json files): ReportActionsList.tsx, useReportActionsScroll.ts, InvertedFlashList/index.tsx, useReportUnreadMessageScrollTracking.ts, plus the new @shopify/flash-list improve-scroll-key-handling patch.
    • Confirmed the change is present at current App HEAD (6e2df6b), i.e. still shipping — not yet reverted:
      • useReportActionsScroll.ts:160 now calls const {windowHeight} = useWindowDimensions();
      • useReportActionsScroll.ts:418-419 computes initialScrollIndex = renderedVisibleReportActions.length - 1; initialScrollIndexParams = {viewOffset: windowHeight};

    Root Cause

    Prior to #95045, the list positioned itself with an initialScrollKey and a data-slice handoff (useFlashListScrollKey, now deleted). #95045 replaced that with an explicit initialScrollIndex (= renderedVisibleReportActions.length - 1) plus initialScrollIndexParams.viewOffset = windowHeight, and a new FlashList patch whose applyInitialScrollAdjustment now does recomputeLayouts(0, this.getDataLength() - 1) and reads getLayout(initialScrollIndex).y/.height, plus a bottom-crop loop that calls getLayout(i) across indices.

    When the whisper is dismissed the visible-actions array shrinks, and a subsequent window resize re-triggers FlashList's initial-index layout path against the new (shorter) data / new windowHeight-derived offset. If the computed index/offset no longer lines up with a measured layout (index past the shortened data, or an unmeasured layout during the resize recompute), the patch's getLayout(...) returns undefined and the .y/.height/.width read throws — a client-side JS error that only appears once a layout change (resize) forces the recompute, which is why it is width/resize-gated and does not reproduce on a stable full-width layout.

    Because this is a client-side render crash introduced by an App PR, the fix belongs in Expensify/App (revert #95045), and the App deploy should remain blocked.

  11. 53 remaining items

  12. added
    Awaiting PaymentAuto-added when associated PR is deployed to production
    and removed on Aug 6, 2026
  13. melvin-bot commented on Aug 6, 2026

    @melvin-bot

    Triggered auto assignment to @mallenexpensify (Awaiting Payment)

  14. melvin-bot commented on Aug 6, 2026

    @melvin-bot

    Payment Summary

    Resolving PRs:

    Upwork Job

    BugZero Checklist (@mallenexpensify)

    • I have confirmed assignees, roles, and Upwork contracts look correct
    • I have paid out Upwork contracts / manual NewDot requests
  15. mallenexpensify commented on Aug 10, 2026

    @mallenexpensify
    Contributor

    Payment Summary

    Contributor: @apeyada paid $250 via Upwork
    Contributor+: @aimane-chnaif due $250 via NewDot

    ^ Test case created. Thx

  16. garrettmknight commented on Sep 14, 2026

    @garrettmknight
    Contributor

    $250 approved for @aimane-chnaif

  17. melvin-bot commented on Oct 12, 2026

    @melvin-bot

    ⚠️ Looks like this issue was linked to a Deploy Blocker here

    If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results.

    If a regression has occurred and you are the assigned CM follow the instructions here.

    If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future.

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.DailyKSv2EngineeringExternalAdded 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