Description
A recurring crash is occurring on iOS in the ReportActionsList component. VirtualizedList._createRenderMask receives an invalid cell range [0, -4] (negative end index), causing an invariant violation.
Sentry issue: https://expensify.sentry.io/issues/APP-6DB
Example event: https://expensify.sentry.io/issues/7290255649/events/6ea8f8a9ccb5478a875afbf95576a8d9/
Impact:
- 40,334 occurrences since first seen (2026-02-25)
- 18,801 users impacted
- Still ongoing as of 2026-05-18
- Affects HybridApp iOS builds (
new.expensify@9.3.61-4)
Error
Invariant Violation: Invalid cells around viewport "[0, -4]" was passed to VirtualizedList._createRenderMask
Component Stack
VirtualizedList
FlatList
CustomFlatList
BaseFlatListWithScrollKey
FlatListWithScrollKey
MoneyRequestReportActionsList
ReportActionsList
ReportScreen
Analysis
The [0, -4] value suggests that VirtualizedList is being passed props that result in a negative cell index being computed for the viewport render mask. The most likely causes are:
- An invalid or negative
initialScrollIndex prop being passed to the FlatList in MoneyRequestReportActionsList or ReportActionsList
- A race condition where the list data changes (shrinks) while an initial scroll offset computed from a larger dataset is still being applied
- The
getItemCount or item layout calculations returning values inconsistent with the actual data length
Steps to Investigate
- Review
MoneyRequestReportActionsList and ReportActionsList for how initialScrollIndex is calculated and whether it can ever produce a value larger than the current item count
- Check if there is any case where the item list shrinks between when the scroll index is computed and when the list renders
- Verify that
getItemLayout (if used) returns consistent values with the data array length
- Add a guard to clamp
initialScrollIndex to Math.max(0, Math.min(index, data.length - 1)) as a defensive fix
Environment
- Platform: iOS (HybridApp)
- Device: iPhone14,6 (iPhone SE 3rd gen)
- OS: iOS 26.4.2
- Release:
new.expensify@9.3.61-4
- Build type:
hybrid_app
Issue Owner
Current Issue Owner: @WojtekBoman
Upwork Automation - Do Not Edit
- Upwork Job URL: https://www.upwork.com/jobs/~022056337409756110816
- Upwork Job ID: 2056337409756110816
- Last Price Increase: 2026-05-18
Description
A recurring crash is occurring on iOS in the
ReportActionsListcomponent.VirtualizedList._createRenderMaskreceives an invalid cell range[0, -4](negative end index), causing an invariant violation.Sentry issue: https://expensify.sentry.io/issues/APP-6DB
Example event: https://expensify.sentry.io/issues/7290255649/events/6ea8f8a9ccb5478a875afbf95576a8d9/
Impact:
new.expensify@9.3.61-4)Error
Component Stack
Analysis
The
[0, -4]value suggests thatVirtualizedListis being passed props that result in a negative cell index being computed for the viewport render mask. The most likely causes are:initialScrollIndexprop being passed to theFlatListinMoneyRequestReportActionsListorReportActionsListgetItemCountor item layout calculations returning values inconsistent with the actual data lengthSteps to Investigate
MoneyRequestReportActionsListandReportActionsListfor howinitialScrollIndexis calculated and whether it can ever produce a value larger than the current item countgetItemLayout(if used) returns consistent values with the data array lengthinitialScrollIndextoMath.max(0, Math.min(index, data.length - 1))as a defensive fixEnvironment
new.expensify@9.3.61-4hybrid_appIssue Owner
Current Issue Owner: @WojtekBomanUpwork Automation - Do Not Edit