BabylonReactNative
BabylonReactNative copied to clipboard
Add Support for React-Native 74 and 75
For questions, please use the forum.
Is your feature request related to a problem? Please describe. React Native released version 74 in April and 75 on August 14, 2024. Can we please have support for that?
Describe the solution you'd like I am not able to run the app with RN version 0.74.5, I want app to run with latest React Native version
Errors that I am receiving
It compiles fine but crashes at runtime with the following error
E terminating due to uncaught exception of type std::logic_error: Not implemented
A Fatal signal 6 (SIGABRT), code -1 (SI_QUEUE) in tid 6035 (mqt_js), pid 5842 (xx.xx.xx)
Additional context Add any other context or screenshots about the feature request here.
I'm taking a look.
0.74.2 is ok but 0.74.3 is not. Now searching for the breaking change.
You are right, I can confirm that I am able to run the app on 0.74.2
https://github.com/facebook/react-native/releases/tag/v0.74.3
I could get a callstack:
/base.apk!libhermes.so (BuildId: 7f8ff6385b5fe455c03f7b48cdae12ba78b8c714)
/base.apk!libBabylonNative.so (BabylonNative::Initialize(facebook::jsi::Runtime&, std::__ndk1::function<void (std::__ndk1::function<void ()>)>)+104) (BuildId: b431f252b69276ed8904a3dd383684bd86d07dd1)
/base.apk!libBabylonNative.so (Java_com_babylonreactnative_BabylonNativeInterop_00024BabylonNative_initialize+164)
tldr: it looks like an initialization issue with Hermes but no version bump in changelog.
@nmongiya I'm testing on Android for practical reason. Do you repro this crash on iOS as well?
I can see a different version of hermes-android with the same version as RN but I can't find a package/build/changelog for that.
Also, I unzipped the .apk. libhermes.so file is different between both version but nothing striking when looking at symbols with objdump.
I am not using hermes for this project.
Also I have noticed some other error while playing with 74.2.
Multiple vertex buffers with the same attribute cannot be recorded
The vertex buffer error is on the JS side and is not related to the RN version. It should happen with the web version as well.
@CedricGuillemet Hello, mate! Any updates? Is anyone working on adding the support? 👀
Hi @dmitryshostak , I'm working on it ATM. no ETA yet. you can follow progress of this PR : https://github.com/BabylonJS/BabylonReactNative/pull/647
I've also been getting crashes on 0.73 when working on this PR: #654 I thought its something related to my PR thankfully its not, 0.75 works as expected.
I've been getting the issue immediately after calling BabylonNative::Initialize(*GetJSIRuntime(bridge), std::move(jsDispatcher)); which looks like an issue with accessing jsi runtime?
There have been some changes around this here: https://github.com/reactwg/react-native-new-architecture/discussions/160 maybe some fixes didn't get backported to 0.73?
@okwasniewski yes, there is an issue open for it : https://github.com/BabylonJS/BabylonReactNative/issues/655#issuecomment-2348225773 a new virtual method has been added between 0.74.2 and 0.74.3 so ABI is broken. I didn't check 0.73. I was expecting this major version to work as 0.74.0 to 0.74.2 work
We experience the same issue using react-native 0.75.4 on both android and ios. Did you manage to find a workaround for this?
any update?
any update?
Hi @mikevocalz , this is still on our roadmap but not much progress so far.
any updates? i tried using in react-native 0.76.9 and i got could not initialize babylon native React on my app screen
any updates? i tried using in react-native 0.76.9 and i got
could not initialize babylon native Reacton my app screen
Sorry, no update yet.
Fixed by https://github.com/BabylonJS/BabylonReactNative/pull/665