question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

SDK 39 Renanimated V2 android standalone apk crashing on load

See original GitHub issue

🐛 Bug Report

Summary of Issue

When building an apk using Expo SDK 39 with the reanimated V2 Configuration, the standalone app will not open and crashes.

Edit(2020-10-08): This seems to be not specific to building the apk. But simply running the app in production mode (i.e. expo start --no-dev) should crash on load.

Environment - output of expo diagnostics & the platform(s) you’re targeting

OS: Windows

Expo CLI 3.27.13 environment info: System: Binaries: Node: 12.14.1 - C:\Program Files\nodejs\node.EXE Yarn: 1.22.4 - C:\Program Files (x86)\Yarn\bin\yarn.CMD npm: 6.13.4 - C:\Program Files\nodejs\npm.CMD IDEs: Android Studio: Version 4.0.0.0 AI-193.6911.18.40.6626763 npmPackages: expo: ~39.0.0 => 39.0.3 react: ~16.13.0 => 16.13.1 react-dom: ~16.13.0 => 16.13.1 react-native: https://github.com/expo/react-native/archive/sdk-39.0.2.tar.gz => 0.63.2 react-native-web: 0.13.13 => 0.13.13 Expo Workflow: managed

Reproducible Demo

I initially found this when trying to migrate my own project, but the same issue is reproduceable in the ‘with-reanimated2’ create react native app template. Note this works fine running locally off an expo start.

Note: I am not able to test if this works on iOS.

Steps to Reproduce

  1. run npx create-react-native-app --template with-reanimated2
  2. expo build:android
  3. install .apk on emulator/phone
  4. open app

Expected Behavior vs Actual Behavior

The app crashes while opening. And I got the following from an ‘adb logcat *:E’ on my emulator.

10-05 15:21:08.680 27460 27460 E AndroidRuntime: FATAL EXCEPTION: main
10-05 15:21:08.680 27460 27460 E AndroidRuntime: Process: com.loganlim.testReanimatedV2, PID: 27460
10-05 15:21:08.680 27460 27460 E AndroidRuntime: java.lang.RuntimeException: Expo encountered a fatal error: Invariant Violation: TurboModuleRegistry.getEnforcing(...): 'NativeReanimated' could not be found. Verify that a module by this name is registered in the native binary., stack:
10-05 15:21:08.680 27460 27460 E AndroidRuntime: exports@23:286
10-05 15:21:08.680 27460 27460 E AndroidRuntime: getEnforcing@27:169
10-05 15:21:08.680 27460 27460 E AndroidRuntime: <unknown>@747:222
10-05 15:21:08.680 27460 27460 E AndroidRuntime: v@2:1473
10-05 15:21:08.680 27460 27460 E AndroidRuntime: <unknown>@746:156
10-05 15:21:08.680 27460 27460 E AndroidRuntime: v@2:1473
10-05 15:21:08.680 27460 27460 E AndroidRuntime: <unknown>@741:5441
10-05 15:21:08.680 27460 27460 E AndroidRuntime: v@2:1473
10-05 15:21:08.680 27460 27460 E AndroidRuntime: <unkno
10-05 15:21:08.680 27460 27460 E AndroidRuntime:        at host.exp.exponent.experience.q.F(BaseExperienceActivity.java:7)
10-05 15:21:08.680 27460 27460 E AndroidRuntime:        at host.exp.exponent.experience.a.run(Unknown Source:2)
10-05 15:21:08.680 27460 27460 E AndroidRuntime:        at android.os.Handler.handleCallback(Handler.java:907)
10-05 15:21:08.680 27460 27460 E AndroidRuntime:        at android.os.Handler.dispatchMessage(Handler.java:99)
10-05 15:21:08.680 27460 27460 E AndroidRuntime:        at android.os.Looper.loop(Looper.java:223)
10-05 15:21:08.680 27460 27460 E AndroidRuntime:        at android.app.ActivityThread.main(ActivityThread.java:7478)
10-05 15:21:08.680 27460 27460 E AndroidRuntime:        at java.lang.reflect.Method.invoke(Native Method)
10-05 15:21:08.680 27460 27460 E AndroidRuntime:        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:549)
10-05 15:21:08.680 27460 27460 E AndroidRuntime:        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:941)
10-05 15:21:08.788   559   642 E InputDispatcher: channel '7198952 com.loganlim.testReanimatedV2/host.exp.exponent.MainActivity (server)' ~ Channel is unrecoverably broken and will be disposed!
10-05 15:21:08.793   559  1825 E SurfaceControl: Call to SurfaceControl.closeTransaction without matching openTransaction

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:18 (7 by maintainers)

github_iconTop GitHub Comments

9reactions
brentvatnecommented, Oct 9, 2020

we’ll hopefully have an answer for next week, thanks for the info.

6reactions
sjchmielacommented, Oct 26, 2020

Bug found and fixed. 🕵️ The change is being applied to SDK39 Android workers, you may expect it to land in the next 12 hours. 🔜

Read more comments on GitHub >

github_iconTop Results From Across the Web

Expo - standalone APK crashing when running on physical ...
Some steps I have taken: Reinstalled expo-cli; Reinstalled react-native; Ran npm-update; Manually downgraded my sdkVersion to 37.0.0 in my app ...
Read more >
react-native-reanimated - Bountysource
A SIGABRT crash on Android, possibly with an external cause, but with Reanimated at the top of the stacktrace. Expected behavior. Don't crash...
Read more >
expo-contacts - NPM Package Versions - Socket - Socket.dev
Provides access to the phone's system contacts. Version: 10.2.0 was published by tsapeta. Start using Socket to analyze expo-contacts and its 2 dependencies ......
Read more >
@expo/metro-config | Yarn - Package Manager
This is the log of notable changes to the Expo client that are developer-facing. Package-specific changes not released in any SDK will be...
Read more >
failed to initialize react-native-reanimated library - You.com
I try to make an internal distribution build, on android it's ok but on my ... for AppCenter SDK integration. rnpm-install info Linking...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found