expo: [expo-gl] Android app crash after libexpo-gl.so loaded
🐛 Bug Report
Environment
Expo CLI 3.17.5 environment info:
System:
OS: macOS 10.15.2
Shell: 5.7.1 - /bin/zsh
Binaries:
Node: 12.16.1 - ~/.nvm/versions/node/v12.16.1/bin/node
Yarn: 1.22.0 - ~/.nvm/versions/node/v12.16.1/bin/yarn
npm: 6.13.4 - ~/.nvm/versions/node/v12.16.1/bin/npm
Watchman: 4.9.0 - /usr/local/bin/watchman
IDEs:
Android Studio: 3.5 AI-191.8026.42.35.6010548
Xcode: 11.4/11E146 - /usr/bin/xcodebuild
npmPackages:
react: 16.11.0 => 16.11.0
react-native: 0.62.0 => 0.62.0
npmGlobalPackages:
expo-cli: 3.17.5
Target : React Native Android
Steps to Reproduce
Launch App
Expected Behavior
No crash
Actual Behavior
App crash after execution of GLView.createContextAsync(); or await tf.ready();
In Logcat :
2020-04-01 14:23:58.501 8177-8177/com.tensorflowapp D/ScrollView: initGoToTop
2020-04-01 14:23:58.650 8177-8177/com.tensorflowapp D/ViewRootImpl@9cfe773[MainActivity]: Relayout returned: old=[0,0][1080,1920] new=[0,0][1080,1920] result=0x1 surface={valid=true 493719822336} changed=false
2020-04-01 14:23:58.670 8177-8891/com.tensorflowapp D/SoLoader: About to load: libexpo-gl.so
2020-04-01 14:23:58.671 8177-8891/com.tensorflowapp D/SoLoader: libexpo-gl.so not found on /data/data/com.tensorflowapp/lib-main
2020-04-01 14:23:58.671 8177-8891/com.tensorflowapp D/SoLoader: libexpo-gl.so found on /data/app/com.tensorflowapp-LFEiOec5Q3Fag-tWih-9nw==/lib/arm64
2020-04-01 14:23:58.671 8177-8891/com.tensorflowapp D/SoLoader: Not resolving dependencies for libexpo-gl.so
2020-04-01 14:23:58.674 8177-8177/com.tensorflowapp D/ViewRootImpl@9cfe773[MainActivity]: Relayout returned: old=[0,0][1080,1920] new=[0,0][1080,1920] result=0x1 surface={valid=true 493719822336} changed=false
2020-04-01 14:23:58.678 8177-8891/com.tensorflowapp D/SoLoader: Loaded: libexpo-gl.so
2020-04-01 14:23:58.685 8177-8891/com.tensorflowapp A/libc: Fatal signal 6 (SIGABRT), code -6 in tid 8891 (mqt_js)
Reproducible Demo
Repo here : https://github.com/alenoir/tesorflowapp
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 29 (17 by maintainers)
Commits related to this issue
- Downgrade RN to 0.61.4. Flipper causes crash with expo-gl. See https://github.com/expo/expo/issues/7575 — committed to nicholas/tfjs_issue_3197 by nicholas 4 years ago
@tsapeta Thanks for the quick reply, might be a different underlying issue though: https://github.com/expo/expo/issues/16887
Thanks for the report @StampixSMO. We’ll investigate that and release a new version soon as the SDK45 release is coming 😉
^ Small correction because
expo-gl-cppshouldn’t be installed directly, for React Native 0.62 please useexpo-gl@8.2.0that solved this issue.I ran into an issue where npm was automatically upgrading to 0.62.2. After ensuring that it downgraded to 0.61.4 and rebuilding, it started working. Flipper was only added as of 0.62 so I didn’t have to edit anything else.
As an experiment I tried preventing flipper from being added to my 0.62.2 copy (including removing the initializeFlipper function in MainApplication.java, and ReactNativeFlipper.java from app/src/debug/…), but it still crashed.
FYI: @LevanSanadiradze I can get 0.61.5 work as well
@wood After downgrading to 0.61.4 removing file
app/android/app/src/debug/java/com/app/ReactNativeFlipper.javaand removingflipper-fresco-pluginlike in a diff bellow, your example started working@jbrew138 can you check if those changes fix the issue for you?