ListMetricsAggregator must be notified of list content layout before resolving offsets
Description
We are receiving this crash on Android devices, observed it on Firebase Crashlytics but It does not contain any logs. We could not reproduced this crash and would not find any similar bug.
Steps to reproduce
React Native Version
0.74.5
Affected Platforms
Runtime - Android
Output of npx react-native info
System:
OS: macOS 14.3.1
CPU: (8) arm64 Apple M3
Memory: 49.61 MB / 16.00 GB
Shell:
version: 3.2.57
path: /bin/bash
Binaries:
Node:
version: 18.19.1
path: ~/.nvm/versions/node/v18.19.1/bin/node
Yarn:
version: 1.22.22
path: ~/.nvm/versions/node/v18.19.1/bin/yarn
npm:
version: 10.2.4
path: ~/.nvm/versions/node/v18.19.1/bin/npm
Watchman:
version: 2024.07.29.00
path: /opt/homebrew/bin/watchman
Managers:
CocoaPods:
version: 1.15.2
path: /Users/alpaye/.rbenv/shims/pod
SDKs:
iOS SDK:
Platforms:
- DriverKit 23.2
- iOS 17.2
- macOS 14.2
- tvOS 17.2
- visionOS 1.0
- watchOS 10.2
Android SDK: Not Found
IDEs:
Android Studio: 2023.1 AI-231.9392.1.2311.11330709
Xcode:
version: 15.2/15C500b
path: /usr/bin/xcodebuild
Languages:
Java:
version: 17.0.10
path: /usr/bin/javac
Ruby:
version: 2.7.8
path: /Users/alpaye/.rbenv/shims/ruby
npmPackages:
"@react-native-community/cli": Not Found
react:
installed: 18.2.0
wanted: 18.2.0
react-native:
installed: 0.74.5
wanted: 0.74.5
react-native-macos: Not Found
npmGlobalPackages:
"*react-native*": Not Found
Android:
hermesEnabled: true
newArchEnabled: false
iOS:
hermesEnabled: true
newArchEnabled: false
Stacktrace or Logs
Fatal Exception: com.facebook.react.common.JavascriptException: Invariant Violation: ListMetricsAggregator must be notified of list content layout before resolving offsets, js engine: hermes, stack:
invariant@1:139225
flowRelativeOffset@1:605334
notifyCellLayout@1:604441
anonymous@1:587750
anonymous@1:611095
invokeGuardedCallbackImpl@1:409136
invokeGuardedCallback@1:409193
invokeGuardedCallbackAndCatchFirstError@1:409225
executeDispatch@1:409354
executeDispatchesAndReleaseTopLevel@1:412758
forEachAccumulated@1:410830
anonymous@1:413121
batchedUpdatesImpl@1:481191
batchedUpdates$1@1:412674
_receiveRootNodeIDEvent@1:412959
receiveEvent@1:475781
__callFunction@1:134915
anonymous@1:133217
__guard@1:134175
callFunctionReturnFlushedQueue@1:133175
at com.facebook.react.modules.core.ExceptionsManagerModule.reportException(ExceptionsManagerModule.java:65)
at java.lang.reflect.Method.invoke(Method.java)
at com.facebook.react.bridge.JavaMethodWrapper.invoke(JavaMethodWrapper.java:372)
at com.facebook.react.bridge.JavaModuleWrapper.invoke(JavaModuleWrapper.java:146)
at com.facebook.jni.NativeRunnable.run(NativeRunnable.java)
at android.os.Handler.handleCallback(Handler.java:958)
at android.os.Handler.dispatchMessage(Handler.java:99)
at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:27)
at android.os.Looper.loopOnce(Looper.java:230)
at android.os.Looper.loop(Looper.java:319)
at com.facebook.react.bridge.queue.MessageQueueThreadImpl$4.run(MessageQueueThreadImpl.java:233)
at java.lang.Thread.run(Thread.java:1012)
Reproducer
Screenshots and Videos
No response
| :warning: | Newer Version of React Native is Available! |
|---|---|
| :information_source: | You are on a supported minor version, but it looks like there's a newer patch available - 0.74.6. Please upgrade to the highest patch for your minor or latest and verify if the issue persists (alternatively, create a new project and repro the issue in it). If it does not repro, please let us know so we can close out this issue. This helps us ensure we are looking at issues that still exist in the most recent releases. |
| :warning: | Missing Reproducible Example |
|---|---|
| :information_source: | We could not detect a reproducible example in your issue report. Please provide either:
|
| :warning: | Newer Version of React Native is Available! |
|---|---|
| :information_source: | You are on a supported minor version, but it looks like there's a newer patch available - undefined. Please upgrade to the highest patch for your minor or latest and verify if the issue persists (alternatively, create a new project and repro the issue in it). If it does not repro, please let us know so we can close out this issue. This helps us ensure we are looking at issues that still exist in the most recent releases. |
| :warning: | Missing Reproducible Example |
|---|---|
| :information_source: | We could not detect a reproducible example in your issue report. Please provide either:
|
anyone?
anyone ???
We could not reproduced this crash and would not find any similar bug.
@egealpay we can't help you without a way to reproduce this crash
I have the same problem as well. please help
I’m experiencing the same issue. Could you please assist?
I know this isn’t the best solution, but for now, I added comments to the following in node_modules > @react-native > virtualized-lists > Lists > ListMetricsAggregator.
Specifically, I looked for the flowRelativeOffset function at line 247 and commented out the three lines below it. This allowed the code to run without any crashes.
This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days.
This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days.
This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days.
This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days.
Did any one fix it?
This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days.
Hi! We also experienced this issue. Encountered on Android 12, 13, and 14. Is there already a fix for this? Thank you!
This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days.
This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days.
i'm facing same issue,
it happen when the app is RTL and we render FlatList inside FlatList
react-native: 0.74.2
same with RTL app
This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days.
This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days.
This issue was closed because the author hasn't provided the requested feedback after 7 days.
same issue , anyone able to solve this ?
Same issue happening in android devices, any update?
any update on this workaround?