-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
3.0.0-rc.2 Android - TypeError: Cannot read property 'stateNode' of undefined #3534
Comments
Same problem |
Facing the same problem with |
Hey @kyle-ssg, any chance you are using @gorhom's bottom-sheet, too? Error trace:
|
Hmm, I was but I could replicate this by rendering a plain reanimated view in an empty app too. See https://github.com/kyle-ssg/reanimated-reproduction/blob/main/mobile/app/App.tsx#L5 |
Facing the same issue on new Archtecture |
@kyle-ssg Did you find any workaround am also facing the same issue. If I have <Animated. View /> it's failing |
Any solution till now? |
Did you find the solution |
The same problem continues. |
Yeah just to confirm, haven't found a workaround for this. |
It was worked for me when I upgraded reanimated to "3.0.0-rc.3" Combination of below dependencies was worked for me : |
Hey @kyle-ssg, thanks for submitting this issue and marking other issues as duplicate. Based on the repro you have provided, I was able to successfully reproduce the issue on app launch. We will investigate this error further. |
The root cause of the issue is the fact that Reanimated uses Fabric mode while the app still runs on Paper (old renderer): As you can see, there's no Based on the value of The problem is that for some reason React Native doesn't enable Fabric. This may be because your app is totally out-of-sync with React Native 0.69.5 template. In particular, the Android app still runs on Paper because the following method is missing: @Override
protected ReactRootView createRootView() {
ReactRootView reactRootView = new ReactRootView(getContext());
// If you opted-in for the New Architecture, we enable the Fabric Renderer.
reactRootView.setIsFabric(BuildConfig.IS_NEW_ARCHITECTURE_ENABLED);
return reactRootView;
} Additionally, many of the third-party libraries that you use are not Fabric-compatible yet, for instance:
I've replaced Closing this issue as it's not a bug in Reanimated, but a config issue on your side. |
With Fabric enabled, the signed APK app crashes on first launch. That's why I disable Fabric. |
@khushal87 facing the same issue when playing around with @gorhom's bottom-sheet |
|
@tomekzaw Thanks so much for the explaination and the |
|
Since yesterday I got my setup working (iOS and android) with quite a few dependencies, including @gorhom's bottom sheet, though from this I learnt I won't switch to the new architecture for a while, seems too risky and some really important modules aren't ready. A few things:
Here's a list of dependencies that currently work for me
A quick note on the above. In order to work, @react-native-community/datetimepicker requires this in react-native-config.js
These don't work
|
Hey @kyle-ssg do you recommend not upgrading to new arch with the bottom-sheet version 4.4.5? |
Is there any way I can use it with newArchitecture = true & fabric = false? |
@prince-sugarfit nope, we don't support this currently (and honestly we don't plan to). |
Is there any workaround to fix this issue? (I always get this issue using Gorhom + BottomSheetVirtuslizedList). Only crash with Fabric = true |
If someone is running into similar issue (for me it was property 'version' of undefined) my solution was to modify properly metro.config.js. I had react-native-svg-transformer included in project as well and you need to follow the new way to integrate it on it's official github page. |
Thanks for the tip, had that in expo-app and I simply needed to set sourceExts the way official documentation says it should be set (same way as assetExts) |
Description
I'm attempting to use Fabric with 3.0.0-rc.2. iOS works fine however on Android I get the following attempting to render an Animated.View.
Steps to reproduce
Render an
<Animated.View/>
Snack or a link to a repository
https://github.com/kyle-ssg/reanimated-reproduction
Reanimated version
3.0.0-rc.2
React Native version
0.69.5 (I can confirm this also happens on RN 0.70.rc-4)
Platforms
Android
JavaScript runtime
JSC
Workflow
React Native (without Expo)
Architecture
Fabric (New Architecture)
Build type
Debug mode
Device
Android emulator
Device model
No response
Acknowledgements
Yes
The text was updated successfully, but these errors were encountered: