React-native-navigation: Crash on Android (NavigationReactEventEmitter on launch)

Created on 24 Nov 2017  路  14Comments  路  Source: wix/react-native-navigation

Issue Description

We received a crash report from one of our android user devices while it launched:

Stacktrace

java.lang.NullPointerException
    NavigationReactEventEmitter.java:17 com.reactnativenavigation.bridge.NavigationReactEventEmitter.<init>
    NavigationReactGateway.java:114 com.reactnativenavigation.react.NavigationReactGateway.onReactContextInitialized
    NavigationReactGateway.java:24 com.reactnativenavigation.react.NavigationReactGateway.access$000
    NavigationReactGateway.java:174 com.reactnativenavigation.react.NavigationReactGateway$ReactNativeHostImpl.onReactContextInitialized
    ReactInstanceManager.java:900 com.facebook.react.ReactInstanceManager$5.run
    Handler.java:725 android.os.Handler.handleCallback
    Handler.java:92 android.os.Handler.dispatchMessage
    Looper.java:176 android.os.Looper.loop
    ActivityThread.java:5365 android.app.ActivityThread.main
    Method.java:-2 java.lang.reflect.Method.invokeNative
    Method.java:511 java.lang.reflect.Method.invoke
    ZygoteInit.java:1102 com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run
    ZygoteInit.java:869 com.android.internal.os.ZygoteInit.main
    NativeStart.java:-2 dalvik.system.NativeStart.main

Here's what happened to the device right before the crash:
screen shot 2017-11-24 at 09 23 44


Environment

  • React Native Navigation version: 1.1.278
  • React Native version: 0.49.5
  • Platform(s) (iOS, Android, or both?): Android
  • Device info (Simulator/Device? OS version? Debug/Release?): Device (Samsung
    SM-T110) Android 4.2.2 (API 17) Release

Threads:

screen shot 2017-11-24 at 09 24 51
screen shot 2017-11-24 at 09 25 03
screen shot 2017-11-24 at 09 25 16
screen shot 2017-11-24 at 09 25 27
screen shot 2017-11-24 at 09 25 38
screen shot 2017-11-24 at 09 25 46
screen shot 2017-11-24 at 09 25 56
screen shot 2017-11-24 at 09 26 06
screen shot 2017-11-24 at 09 26 14
screen shot 2017-11-24 at 09 26 21

Android more info needed

Most helpful comment

@pqkluan are we able to re-open this given that the crash doesn't seem to be isolated to just one API version?

All 14 comments

Sorry that I can't get much info from the crash log, but I notice that the device's version is a bit outdated Android 4.2.2 (API 17).

You could try test the app on another device with the same version to check if it was the cause.

Hmm, I wish I had a way to reproduce this. That crash came into our crash reporter (bugsnag) so I'm not sure what the user did. I was secretly hoping that you would know.

I'll close this issue for now due to the lack of information. If the problem still exists with the latest version, feel free to re-open.

@SudoPlz any updates on this, please?

@ossamaweb Nope, no news :/

I think it happens when launching the app from a custom launcher app. I'm getting this:

Custom launcher app? Not sure what that is, but I'm not using anything custom tbh.

Oh got it, not sure how I can check that.

@SudoPlz can you confirm you are still using v 1.1.278 ? We are on 1.1.346 and getting a similar report (also caught via bugsnag)

I don't think it's API specific, as we're getting it on a wide range of OSs (see attached)

screen shot 2018-03-19 at 20 31 25

screen shot 2018-03-19 at 20 31 33

We are going to upgrade to the latest version of RNN this week and see if that changes anything (wee are due to anyway). Unfortunately, because this happens randomly when re-launching the app under unknown conditions, is incredibly difficult to reproduce, and we are pretty much relying on bug reports from production where we have enough volume for bug reports

Yep I was using 1.1.278 when I first saw that issue. I'm now using 1.1.314 and I still get that issue.

@pqkluan are we able to re-open this given that the crash doesn't seem to be isolated to just one API version?

+1 I am also running into the same exception across multiple android versions.

Was this page helpful?
0 / 5 - 0 ratings