Recent updates prevent app from starting


#1

I have a big issue right now:
After updating cordova and ionic few days ago I was successfully working in debug mode.
Now I wanted to create an update for ios and android, build went fine, but then on the devices the app stucks at the splashscreen for ios AND android.

So for android I found following error in adb logcat:

11-25 07:06:43.254 26608 26608 I art     : Rejecting re-init on previously-failed class java.lang.Class<com.android.webview.chromium.eb>: java.lang.NoClassDefFoundError: Failed resolution of: Landroid/webkit/RenderProcessGoneDetail;
11-25 07:06:43.254 26608 26608 I art     :   at com.android.webview.chromium.Ap com.android.webview.chromium.WebViewChromiumFactoryProvider.G(android.webkit.WebView, android.content.Context) (WebViewChromiumFactoryProvider.java:323)
11-25 07:06:43.254 26608 26608 I art     :   at void com.android.webview.chromium.WebViewChromium.init(java.util.Map, boolean) (WebViewChromium.java:42)
11-25 07:06:43.254 26608 26608 I art     :   at void android.webkit.WebView.<init>(android.content.Context, android.util.AttributeSet, int, int, java.util.Map, boolean) (WebView.java:636)
11-25 07:06:43.254 26608 26608 I art     :   at void android.webkit.WebView.<init>(android.content.Context, android.util.AttributeSet, int, int) (WebView.java:572)
11-25 07:06:43.254 26608 26608 I art     :   at void android.webkit.WebView.<init>(android.content.Context, android.util.AttributeSet, int) (WebView.java:555)
11-25 07:06:43.254 26608 26608 I art     :   at void android.webkit.WebView.<init>(android.content.Context, android.util.AttributeSet) (WebView.java:542)
11-25 07:06:43.254 26608 26608 I art     :   at void org.apache.cordova.engine.SystemWebView.<init>(android.content.Context, android.util.AttributeSet) ((null):-1)
11-25 07:06:43.254 26608 26608 I art     :   at void org.apache.cordova.engine.SystemWebView.<init>(android.content.Context) ((null):-1)
11-25 07:06:43.254 26608 26608 I art     :   at void org.apache.cordova.engine.SystemWebViewEngine.<init>(android.content.Context, org.apache.cordova.CordovaPreferences) ((null):-1)
11-25 07:06:43.254 26608 26608 I art     :   at java.lang.Object java.lang.reflect.Constructor.newInstance0!(java.lang.Object[]) (Constructor.java:-2)
11-25 07:06:43.254 26608 26608 I art     :   at java.lang.Object java.lang.reflect.Constructor.newInstance(java.lang.Object[]) (Constructor.java:430)
11-25 07:06:43.254 26608 26608 I art     :   at org.apache.cordova.CordovaWebViewEngine org.apache.cordova.CordovaWebViewImpl.createEngine(android.content.Context, org.apache.cordova.CordovaPreferences) ((null):-1)
11-25 07:06:43.254 26608 26608 I art     :   at org.apache.cordova.CordovaWebViewEngine org.apache.cordova.CordovaActivity.makeWebViewEngine() ((null):-1)
11-25 07:06:43.254 26608 26608 I art     :   at org.apache.cordova.CordovaWebView org.apache.cordova.CordovaActivity.makeWebView() ((null):-1)
11-25 07:06:43.254 26608 26608 I art     :   at void org.apache.cordova.CordovaActivity.init() ((null):-1)
11-25 07:06:43.254 26608 26608 I art     :   at void org.apache.cordova.CordovaActivity.loadUrl(java.lang.String) ((null):-1)
11-25 07:06:43.254 26608 26608 I art     :   at void de.xxxxx.MainActivity.onCreate(android.os.Bundle) ((null):-1)
11-25 07:06:43.254 26608 26608 I art     :   at void android.app.Activity.performCreate(android.os.Bundle) (Activity.java:6743)
11-25 07:06:43.254 26608 26608 I art     :   at void android.app.Instrumentation.callActivityOnCreate(android.app.Activity, android.os.Bundle) (Instrumentation.java:1134)
11-25 07:06:43.254 26608 26608 I art     :   at android.app.Activity android.app.ActivityThread.performLaunchActivity(android.app.ActivityThread$ActivityClientRecord, android.content.Intent) (ActivityThread.java:2715)
11-25 07:06:43.254 26608 26608 I art     :   at void android.app.ActivityThread.handleLaunchActivity(android.app.ActivityThread$ActivityClientRecord, android.content.Intent, java.lang.String) (ActivityThread.java:2848)
11-25 07:06:43.254 26608 26608 I art     :   at void android.app.ActivityThread.-wrap12(android.app.ActivityThread, android.app.ActivityThread$ActivityClientRecord, android.content.Intent, java.lang.String) (ActivityThread.java:-1)
11-25 07:06:43.254 26608 26608 I art     :   at void android.app.ActivityThread$H.handleMessage(android.os.Message) (ActivityThread.java:1552)
11-25 07:06:43.255 26608 26608 I art     :   at void android.os.Handler.dispatchMessage(android.os.Message) (Handler.java:102)
11-25 07:06:43.255 26608 26608 I art     :   at void android.os.Looper.loop() (Looper.java:154)
11-25 07:06:43.255 26608 26608 I art     :   at void android.app.ActivityThread.main(java.lang.String[]) (ActivityThread.java:6334)
11-25 07:06:43.255 26608 26608 I art     :   at java.lang.Object java.lang.reflect.Method.invoke!(java.lang.Object, java.lang.Object[]) (Method.java:-2)
11-25 07:06:43.255 26608 26608 I art     :   at void com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run() (ZygoteInit.java:886)
11-25 07:06:43.255 26608 26608 I art     :   at void com.android.internal.os.ZygoteInit.main(java.lang.String[]) (ZygoteInit.java:776)
11-25 07:06:43.255 26608 26608 I art     : Caused by: java.lang.ClassNotFoundException: Didn't find class "android.webkit.RenderProcessGoneDetail" on path: DexPathList[[zip file "/data/app/com.android.chrome-2/base.apk"],nativeLibraryDirectories=[/data/app/com.android.chrome-2/lib/arm64, /data/app/com.android.chrome-2/base.apk!/lib/arm64-v8a, /system/lib64, /vendor/lib64]]
11-25 07:06:43.255 26608 26608 I art     :   at java.lang.Class dalvik.system.BaseDexClassLoader.findClass(java.lang.String) (BaseDexClassLoader.java:56)
11-25 07:06:43.255 26608 26608 I art     :   at java.lang.Class java.lang.ClassLoader.loadClass(java.lang.String, boolean) (ClassLoader.java:380)
11-25 07:06:43.255 26608 26608 I art     :   at java.lang.Class java.lang.ClassLoader.loadClass(java.lang.String) (ClassLoader.java:312)
11-25 07:06:43.255 26608 26608 I art     :   at com.android.webview.chromium.Ap com.android.webview.chromium.WebViewChromiumFactoryProvider.G(android.webkit.WebView, android.content.Context) (WebViewChromiumFactoryProvider.java:323)
11-25 07:06:43.255 26608 26608 I art     :   at void com.android.webview.chromium.WebViewChromium.init(java.util.Map, boolean) (WebViewChromium.java:42)
11-25 07:06:43.255 26608 26608 I art     :   at void android.webkit.WebView.<init>(android.content.Context, android.util.AttributeSet, int, int, java.util.Map, boolean) (WebView.java:636)
11-25 07:06:43.255 26608 26608 I art     :   at void android.webkit.WebView.<init>(android.content.Context, android.util.AttributeSet, int, int) (WebView.java:572)
11-25 07:06:43.255 26608 26608 I art     :   at void android.webkit.WebView.<init>(android.content.Context, android.util.AttributeSet, int) (WebView.java:555)
11-25 07:06:43.255 26608 26608 I art     :   at void android.webkit.WebView.<init>(android.content.Context, android.util.AttributeSet) (WebView.java:542)
11-25 07:06:43.255 26608 26608 I art     :   at void org.apache.cordova.engine.SystemWebView.<init>(android.content.Context, android.util.AttributeSet) ((null):-1)
11-25 07:06:43.255 26608 26608 I art     :   at void org.apache.cordova.engine.SystemWebView.<init>(android.content.Context) ((null):-1)
11-25 07:06:43.255 26608 26608 I art     :   at void org.apache.cordova.engine.SystemWebViewEngine.<init>(android.content.Context, org.apache.cordova.CordovaPreferences) ((null):-1)
11-25 07:06:43.255 26608 26608 I art     :   at java.lang.Object java.lang.reflect.Constructor.newInstance0!(java.lang.Object[]) (Constructor.java:-2)
11-25 07:06:43.255 26608 26608 I art     :   at java.lang.Object java.lang.reflect.Constructor.newInstance(java.lang.Object[]) (Constructor.java:430)
11-25 07:06:43.255 26608 26608 I art     :   at org.apache.cordova.CordovaWebViewEngine org.apache.cordova.CordovaWebViewImpl.createEngine(android.content.Context, org.apache.cordova.CordovaPreferences) ((null):-1)
11-25 07:06:43.255 26608 26608 I art     :   at org.apache.cordova.CordovaWebViewEngine org.apache.cordova.CordovaActivity.makeWebViewEngine() ((null):-1)
11-25 07:06:43.255 26608 26608 I art     :   at org.apache.cordova.CordovaWebView org.apache.cordova.CordovaActivity.makeWebView() ((null):-1)
11-25 07:06:43.255 26608 26608 I art     :   at void org.apache.cordova.CordovaActivity.init() ((null):-1)
11-25 07:06:43.255 26608 26608 I art     :   at void org.apache.cordova.CordovaActivity.loadUrl(java.lang.String) ((null):-1)
11-25 07:06:43.255 26608 26608 I art     :   at void de.xxxxx.MainActivity.onCreate(android.os.Bundle) ((null):-1)
11-25 07:06:43.255 26608 26608 I art     :   at void android.app.Activity.performCreate(android.os.Bundle) (Activity.java:6743)
11-25 07:06:43.255 26608 26608 I art     :   at void android.app.Instrumentation.callActivityOnCreate(android.app.Activity, android.os.Bundle) (Instrumentation.java:1134)
11-25 07:06:43.255 26608 26608 I art     :   at android.app.Activity android.app.ActivityThread.performLaunchActivity(android.app.ActivityThread$ActivityClientRecord, android.content.Intent) (ActivityThread.java:2715)
11-25 07:06:43.255 26608 26608 I art     :   at void android.app.ActivityThread.handleLaunchActivity(android.app.ActivityThread$ActivityClientRecord, android.content.Intent, java.lang.String) (ActivityThread.java:2848)
11-25 07:06:43.255 26608 26608 I art     :   at void android.app.ActivityThread.-wrap12(android.app.ActivityThread, android.app.ActivityThread$ActivityClientRecord, android.content.Intent, java.lang.String) (ActivityThread.java:-1)
11-25 07:06:43.255 26608 26608 I art     :   at void android.app.ActivityThread$H.handleMessage(android.os.Message) (ActivityThread.java:1552)
11-25 07:06:43.255 26608 26608 I art     :   at void android.os.Handler.dispatchMessage(android.os.Message) (Handler.java:102)
11-25 07:06:43.255 26608 26608 I art     :   at void android.os.Looper.loop() (Looper.java:154)
11-25 07:06:43.255 26608 26608 I art     :   at void android.app.ActivityThread.main(java.lang.String[]) (ActivityThread.java:6334)
11-25 07:06:43.255 26608 26608 I art     :   at java.lang.Object java.lang.reflect.Method.invoke!(java.lang.Object, java.lang.Object[]) (Method.java:-2)
11-25 07:06:43.255 26608 26608 I art     :   at void com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run() (ZygoteInit.java:886)
11-25 07:06:43.255 26608 26608 I art     :   at void com.android.internal.os.ZygoteInit.main(java.lang.String[]) (ZygoteInit.java:776)
11-25 07:06:43.255 26608 26608 I art     :
11-25 07:06:43.258  1385  1452 D DeviceIdleController: handleMessage(7)
11-25 07:06:43.281 26608 26608 D SystemWebViewEngine: CordovaWebView is running on device made by: OnePlus

Which makes no sense.
According to this page https://developer.android.com/reference/android/webkit/RenderProcessGoneDetail.html The not found class has been introduced in API Level 26. However, I am testing on an API level 25 device. My config.xml contains

        <preference name="android-minSdkVersion" value="19" />
        <preference name="android-targetSdkVersion" value="27" />

I tried to remove the platform android completely, and re-added it. Same result.

On iOS, the app also stucks at the splashscreen (even more strange, as this error looks very android specific). But I cannot find anything which looks like an error in the iOS log.

Can anybody help me?

onic info

cli packages: (C:\nvm\v8.4.0\node_modules)

    @ionic/cli-utils  : 1.18.0
    ionic (Ionic CLI) : 3.18.0

global packages:

    cordova (Cordova CLI) : 7.1.0

local packages:

    @ionic/app-scripts : 3.1.2
    Cordova Platforms  : android 6.4.0
    Ionic Framework    : ionic-angular 3.9.2

System:

    Android SDK Tools : 25.2.5
    Node              : v8.4.0
    npm               : 5.3.0
    OS                : Windows 10

Environment Variables:

    ANDROID_HOME : C:\AndroidSDK

Misc:

    backend : legacy

edit:
Ok maybe we have something different here… Not sure, but I have Sentry error reporting in JS code enabled, and just got an email that my app is reporting the error exception {"isTrusted": true} when started. I have no idea what that means.

edit2:
Ok after making the app debuggable I saw no error in console, but after enabling stopping at exception, I found a proper exception. Seems like i upgraded an Rxjs import wrong…
Seems like I imported several operators wrong or not at all (some where not imported before and “just worked” but after the update it seems like they need to be imported explicitly…)


#2

Ok solved it. Actually there where pretty much RXJS imports missing at all after the update. Seems like some things didn’t have to be imported explicitly before, but now have to be imported. (several operators, Observable.fromPromise(), …)
This works in debug mode but not in release build.


#3

could you give some examples how to identify if this is causing problems?
I have similar symptoms in my app and debug build runs well while release build does not go past white screen after splashscreen