-
Notifications
You must be signed in to change notification settings - Fork 25k
Closed
Description
Description
when i make a 0.80.1 project
`import { ActivityIndicator, FlatList, Text, View } from 'react-native';
import { useNavigation } from '@react-navigation/native';
const Test = () => {
const navigation = useNavigation()
return
<FlatList
data={Array.from({ length: 100 })}
keyExtractor={(item, index) => index.toString()}
refreshControl={}
renderItem={()=> {
return <View style={{ width: '100%', height: 40, justifyContent: 'center', alignItems: 'center' }}>
暂无数据
}} />
export default Test;
`
this page use navigation.goBack() will be error, it's happend in android 7
Steps to reproduce
yarn android
React Native Version
0.80.1
Affected Platforms
Runtime - Android
Output of npx @react-native-community/cli info
System:
OS: macOS 15.5
CPU: (10) arm64 Apple M4
Memory: 105.89 MB / 32.00 GB
Shell:
version: "5.9"
path: /bin/zsh
Binaries:
Node:
version: 22.17.0
path: ~/.nvm/versions/node/v22.17.0/bin/node
Yarn:
version: 1.22.22
path: ~/.nvm/versions/node/v22.17.0/bin/yarn
npm:
version: 10.9.2
path: ~/.nvm/versions/node/v22.17.0/bin/npm
Watchman: Not Found
Managers:
CocoaPods:
version: 1.16.2
path: /Users/zs/.rbenv/shims/pod
SDKs:
iOS SDK:
Platforms:
- DriverKit 24.5
- iOS 18.5
- macOS 15.5
- tvOS 18.5
- visionOS 2.5
- watchOS 11.5
Android SDK: Not Found
IDEs:
Android Studio: 2025.1 AI-251.25410.109.2511.13752376
Xcode:
version: 16.4/16F6
path: /usr/bin/xcodebuild
Languages:
Java:
version: 17.0.15
path: /Users/zs/.jenv/shims/javac
Ruby:
version: 3.3.0
path: /Users/zs/.rbenv/shims/ruby
npmPackages:
"@react-native-community/cli":
installed: 19.0.0
wanted: 19.0.0
react:
installed: 19.1.0
wanted: 19.1.0
react-native:
installed: 0.80.1
wanted: 0.80.1
react-native-macos: Not Found
npmGlobalPackages:
"*react-native*": Not Found
Android:
hermesEnabled: true
newArchEnabled: true
iOS:
hermesEnabled: Not found
newArchEnabled: false
Stacktrace or Logs
FATAL EXCEPTION: main
Process: com.rnproj, PID: 9757
java.lang.IndexOutOfBoundsException: getChildDrawingOrder() returned invalid index 1 (child count is 1)
at android.view.ViewGroup.getAndVerifyPreorderedIndex(ViewGroup.java:1735)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3510)
at android.view.View.draw(View.java:17202)
at android.view.View.updateDisplayListIfDirty(View.java:16181)
at android.view.View.draw(View.java:16965)
at android.view.ViewGroup.drawChild(ViewGroup.java:3727)
at com.facebook.react.views.view.ReactViewGroup.drawChild(ReactViewGroup.java:1001)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3537)
at com.facebook.react.views.view.ReactViewGroup.dispatchDraw(ReactViewGroup.java:972)
at android.view.View.draw(View.java:17202)
at com.facebook.react.views.view.ReactViewGroup.draw(ReactViewGroup.java:963)
at android.view.View.updateDisplayListIfDirty(View.java:16181)
at android.view.View.draw(View.java:16965)
at android.view.ViewGroup.drawChild(ViewGroup.java:3727)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3537)
at android.view.View.updateDisplayListIfDirty(View.java:16176)
at android.view.View.draw(View.java:16965)
at android.view.ViewGroup.drawChild(ViewGroup.java:3727)
at androidx.coordinatorlayout.widget.CoordinatorLayout.drawChild(CoordinatorLayout.java:1312)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3513)
MANDATORY Reproducer
https://github.com/luoxiao-ui/rnproj.git
Screenshots and Videos
No response