expo: App freezing on real device, but works with development .apk version

Summary

After installing the preview build, the app is freezing on the splash screen. Development version (using expo-dev-client) works fine.

I just realized I’m not the first one with this issue: github issue

Managed or bare workflow? If you have ios/ or android/ directories in your project, the answer is bare!

bare

What platform(s) does this occur on?

Android, iOS

SDK Version (managed workflow only)

No response

Environment

System: OS: Linux 5.4 Ubuntu 20.04.2 LTS (Focal Fossa) Shell: 5.0.17 - /bin/bash Binaries: Node: 10.24.1 - ~/.nvm/versions/node/v10.24.1/bin/node Yarn: 1.22.5 - /usr/bin/yarn npm: 6.14.12 - ~/.nvm/versions/node/v10.24.1/bin/npm npmPackages: expo: ~44.0.6 => 44.0.6 react: 17.0.1 => 17.0.1 react-dom: 17.0.1 => 17.0.1 react-native: 0.64.3 => 0.64.3 react-native-web: 0.17.7 => 0.17.7 npmGlobalPackages: eas-cli: 0.47.0 Expo Workflow: managed

Reproducible demo

Adb logcat logs:

03-07 23:01:21.163 2952 32116 E pageboostd: prefetch start : app cominflowsoftrave 03-07 23:01:21.164 2952 32116 E pageboostd: cominflowsoftrave, amt 20246528 scnt 29 fcnt 10 03-07 23:01:21.164 2952 32116 E pageboostd: prefetch end : app cominflowsoftrave data_amount 20246528 03-07 23:01:36.082 2952 32131 E pageboostd: alp start : app cominflowsoftrave 03-07 23:01:36.083 2952 32131 E pageboostd: cominflowsoftrave, amt 33150368 scnt 2 fcnt 0 03-07 23:01:36.084 2952 32131 E pageboostd: cominflowsoftrave, amt 20246528 scnt 29 fcnt 10 03-07 23:01:36.084 2952 32131 E pageboostd: alp end : app cominflowsoftrave data_amount 53396896 03-07 23:01:36.102 29659 29659 E inflowsoft.rav: Not starting debugger since process cannot load the jdwp agent. 03-07 23:01:36.223 29659 29659 E e : java.io.IOException: not a readable directory: /data/user/0/com.inflowsoft.rave/files/okhttp 03-07 23:01:36.430 1179 1225 E WindowManager: win=Window{590008c u0 Splash Screen com.inflowsoft.rave EXITING} destroySurfaces: appStopped=false win.mWindowRemovalAllowed=true win.mRemoveOnExit=true win.mViewVisibility=0 caller=com.android.server.wm.ActivityRecord.destroySurfaces:5251 com.android.server.wm.ActivityRecord.destroySurfaces:5232 com.android.server.wm.WindowState.onExitAnimationDone:5626 com.android.server.wm.WindowStateAnimator.onAnimationFinished:332 com.android.server.wm.WindowState.onAnimationFinished:6091 com.android.server.wm.-$$Lambda$dwJG8BAnLlvKNGuDY9U3-haNY4M.onAnimationFinished:2 com.android.server.wm.SurfaceAnimator.lambda$getFinishedCallback$0$SurfaceAnimator:112

My package.json dependencies:

"@expo/vector-icons": "^12.0.5", "@miblanchard/react-native-slider": "^2.1.0", "@react-native-async-storage/async-storage": "~1.15.0", "@react-navigation/native": "^6.0.8", "@react-navigation/native-stack": "^6.5.0", "axios": "^0.26.0", "expo": "~44.0.6", "expo-constants": "~13.0.2", "expo-linear-gradient": "~11.0.3", "expo-location": "~14.0.2", "expo-status-bar": "~1.2.0", "expo-updates": "~0.11.6", "moment": "^2.29.1", "react": "17.0.1", "react-dom": "17.0.1", "react-native": "0.64.3", "react-native-global-props": "^1.1.5", "react-native-modal-datetime-picker": "13.0.1", "react-native-ratings": "^8.1.0", "react-native-reanimated": "~2.3.1", "react-native-root-siblings": "^4.1.1", "react-native-root-toast": "^3.3.0", "react-native-safe-area-context": "3.3.2", "react-native-status-bar-height": "^2.6.0", "react-native-svg": "12.1.1", "react-native-web": "0.17.7", "expo-dev-client": "~0.8.4", "react-native-screens": "~3.10.1", "react-native-gesture-handler": "~2.1.0"

app.json file:

{ "expo": { "name": "rave", "slug": "rave", "version": "0.0.1", "orientation": "portrait", "icon": "./assets/icon.png", "splash": { "image": "./assets/rave-logo.png", "resizeMode": "contain", "backgroundColor": "#ffffff" }, "updates": { "fallbackToCacheTimeout": 0 }, "assetBundlePatterns": [ "**/*" ], "ios": { "supportsTablet": true, "bundleIdentifier": "com.inflowsoft.rave", "buildNumber": "0.0.1", "infoPlist": { "UIBackgroundModes": [ "location", "fetch" ], "NSLocationAlwaysAndWhenInUseUsageDescription": "Rave.App will use your location to provide you info about awesome nearby events", "NSLocationAlwaysUsageDescription": "Rave.App will use your location to provide you info about awesome nearby events", "NSLocationWhenInUseUsageDescription": "Rave.App will use your location to provide you info about awesome nearby events" } }, "android": { "package": "com.inflowsoft.rave", "versionCode": 1, "adaptiveIcon": { "foregroundImage": "./assets/rave-logo.png", "backgroundColor": "#FFFFFF" }, "permissions":["READ_EXTERNAL_STORAGE", "WRITE_EXTERNAL_STORAGE, ACCESS_COARSE_LOCATION", "ACCESS_FINE_LOCATION, FOREGROUND_SERVICE"] }, "web": { "favicon": "./assets/favicon.png" }, "userInterfaceStyle": "automatic" } }

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Comments: 23 (2 by maintainers)

Most upvoted comments

I just upgraded to SDK 45 and am seeing an issue similar to this. I’m using the Managed/Classic build flow.

Appears to be mostly (if not just) Samsung Android devices.

Screen Shot 2022-06-15 at 8 06 10 AM

As previously mentioned, only happens on initial install. Returning to the app later or closing from memory and re-opening does not generate this crash.

We’re going crazy with this issue. App works perfectly on Expo Go. As soon as we compile it, and load it on our device, it crashes. Once we restart the app, it runs just like it did on Expo Go. It also seems to not be an issue on Android version 10, but it’s happening on Android 12. Installed Sentry to try and get a better idea, but it’s very vague with the error being __kernel_rt_sigreturn

After activating hermes I haven’t seen the error in production for more than 3 weeks.

stackoverflow

Did you find any fix for that?

For me the problem was expo-constants package.

By default I had dev release channel and I had properly defined variables for it. But env variable was not defined in “staging”. So that’s why it works for dev build and not in preview build.

@PolyPlugins check every place where you use expo-contants or expo-updates package. Make sure, that you properly defined release channels and env variables for them. Debugging env variables is almost impossible in expo.

Edit: Add release channel to your eas.json file and use it for env variables configuration.

for me it looks like to be from expo-sentry. when I remove it (sentry.init(...) the issue doesn’t happen

Im having same issue

Error: __kernel_rt_sigreturn

Error: Abort
SIGABRT

Error: __epoll_pwait

https://forums.expo.dev/t/crash-with-error-kernel-rt-sigreturn-by-sentry-on-android-run-arm64-v8a-armeabi-v7a-armeabi

Most of the reports are samsung devices: Android 12 arm64-v8a, armeabi-v7a, armeabi

I noticed this errors reports after switching from legacy build to EAS build

Same issue here. It is happening with our latest app on Android (Samsung device tested) just after uninstall > install on the Play Store. Happens only once after initial install and is not happening when we remove cache or data after install.

Here is the crash log from Play Store:

  #00  pc 0x00000000006703bc  /data/app/~~UnONMZiTJ-S0LC1PGR38dg==/com.company.appname-MEmgHOQf_l6ywGu-5gtlVw==/split_config.arm64_v8a.apk!libjsc.so
  #01  pc 0x00000000000005d0  [vdso] (__kernel_rt_sigreturn)
  #02  pc 0x000000000009fca4  /apex/com.android.runtime/lib64/bionic/libc.so (__epoll_pwait+4)
  #03  pc 0x000000000001663c  /system/lib64/libutils.so (android::Looper::pollInner(int)+180)
  #04  pc 0x0000000000016520  /system/lib64/libutils.so (android::Looper::pollOnce(int, int*, int*, void**)+112)
  #05  pc 0x0000000000152c20  /system/lib64/libandroid_runtime.so (android::android_os_MessageQueue_nativePollOnce(_JNIEnv*, _jobject*, long, int)+44)
  #06  pc 0x00000000003fe504  /data/misc/apexdata/com.android.art/dalvik-cache/arm64/boot.oat (art_jni_trampoline+116)```