java.lang.ExceptionInInitializerError

JIRA | lvyunxiao | 2 years ago
  1. 0

    Reproduce Test Steps ========================================================================= 1. Unzip the 'crosswalk-cordova-13.42.322.0-arm.zip' -d localpath(https://download.01.org/crosswalk/releases/crosswalk/android/canary/13.42.322.0/arm/crosswalk-cordova-13.42.322.0-arm.zip) 2. Build, install and launch cordova app: {code} cd /localpath/crosswalk-cordova-13.42.322.0-arm ./bin/create hello1 com.example.hello1 hello1 cd hello1 ./cordova/build cd /bin adb install hello1-debug.apk Launch the hello1, check the behavior {code} Expected Outcome ========================================================================= The app should be launched Actual Outcome ========================================================================= App crash occurred, this issue also exist on ZTE x86 device using crosswalk-cordova-13.42.322.0-x86. Test Builds ========================================================================= ||Version||Test Date|| Test Device || Result || |Canary 13.42.319.0 | 2015.03.24 | Nexus 5 ARM|{color: green}Pass{color}| |Canary 13.42.320.0 | 2015.03.24 | Nexus 5 ARM|{color: green}Pass{color}| |Canary 13.42.321.0 | 2015.03.26 | Nexus 5 ARM|{color: red}Fail{color}| |Canary 13.42.322.0 | 2015.03.26 | Nexus 5 ARM|{color: red}Fail{color}| |Canary 14.42.323.0 | 2015.03.26 | Nexus 5 ARM|{color: red}Fail{color}| |Canary 14.42.324.0 | 2015.03.26 | Nexus 5 ARM|{color: green}Pass{color}| |Canary 14.42.325.0 | 2015.03.26 | Nexus 5 ARM|{color: green}Pass{color}| Log Info ========================================================================= {code} E/AndroidRuntime(13249): FATAL EXCEPTION: main E/AndroidRuntime(13249): Process: com.example.hello1, PID: 13249 E/AndroidRuntime(13249): java.lang.ExceptionInInitializerError E/AndroidRuntime(13249): at org.apache.cordova.CordovaActivity.makeWebView(CordovaActivity.java:340) E/AndroidRuntime(13249): at org.apache.cordova.CordovaActivity.init(CordovaActivity.java:376) E/AndroidRuntime(13249): at org.apache.cordova.CordovaActivity.init(CordovaActivity.java:368) E/AndroidRuntime(13249): at com.example.hello1.hello1.onCreate(hello1.java:31) E/AndroidRuntime(13249): at android.app.Activity.performCreate(Activity.java:5231) E/AndroidRuntime(13249): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087) E/AndroidRuntime(13249): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2148) E/AndroidRuntime(13249): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2233) E/AndroidRuntime(13249): at android.app.ActivityThread.access$800(ActivityThread.java:135) E/AndroidRuntime(13249): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196) E/AndroidRuntime(13249): at android.os.Handler.dispatchMessage(Handler.java:102) E/AndroidRuntime(13249): at android.os.Looper.loop(Looper.java:136) E/AndroidRuntime(13249): at android.app.ActivityThread.main(ActivityThread.java:5001) E/AndroidRuntime(13249): at java.lang.reflect.Method.invoke(Native Method) E/AndroidRuntime(13249): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:785) E/AndroidRuntime(13249): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:601) E/AndroidRuntime(13249): Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Class org.xwalk.core.XWalkCoreWrapper.getBridgeClass(java.lang.String)' on a null object reference E/AndroidRuntime(13249): at org.xwalk.core.XWalkPreferences.setValue(XWalkPreferences.java:106) E/AndroidRuntime(13249): at org.apache.cordova.CordovaWebView.<clinit>(CordovaWebView.java:897) E/AndroidRuntime(13249): ... 16 more {code}

    JIRA | 2 years ago | lvyunxiao
    java.lang.ExceptionInInitializerError
  2. 0

    Reproduce Test Steps ========================================================================= 1. Unzip the 'crosswalk-cordova-13.42.322.0-arm.zip' -d localpath(https://download.01.org/crosswalk/releases/crosswalk/android/canary/13.42.322.0/arm/crosswalk-cordova-13.42.322.0-arm.zip) 2. Build, install and launch cordova app: {code} cd /localpath/crosswalk-cordova-13.42.322.0-arm ./bin/create hello1 com.example.hello1 hello1 cd hello1 ./cordova/build cd /bin adb install hello1-debug.apk Launch the hello1, check the behavior {code} Expected Outcome ========================================================================= The app should be launched Actual Outcome ========================================================================= App crash occurred, this issue also exist on ZTE x86 device using crosswalk-cordova-13.42.322.0-x86. Test Builds ========================================================================= ||Version||Test Date|| Test Device || Result || |Canary 13.42.319.0 | 2015.03.24 | Nexus 5 ARM|{color: green}Pass{color}| |Canary 13.42.320.0 | 2015.03.24 | Nexus 5 ARM|{color: green}Pass{color}| |Canary 13.42.321.0 | 2015.03.26 | Nexus 5 ARM|{color: red}Fail{color}| |Canary 13.42.322.0 | 2015.03.26 | Nexus 5 ARM|{color: red}Fail{color}| |Canary 14.42.323.0 | 2015.03.26 | Nexus 5 ARM|{color: red}Fail{color}| |Canary 14.42.324.0 | 2015.03.26 | Nexus 5 ARM|{color: green}Pass{color}| |Canary 14.42.325.0 | 2015.03.26 | Nexus 5 ARM|{color: green}Pass{color}| Log Info ========================================================================= {code} E/AndroidRuntime(13249): FATAL EXCEPTION: main E/AndroidRuntime(13249): Process: com.example.hello1, PID: 13249 E/AndroidRuntime(13249): java.lang.ExceptionInInitializerError E/AndroidRuntime(13249): at org.apache.cordova.CordovaActivity.makeWebView(CordovaActivity.java:340) E/AndroidRuntime(13249): at org.apache.cordova.CordovaActivity.init(CordovaActivity.java:376) E/AndroidRuntime(13249): at org.apache.cordova.CordovaActivity.init(CordovaActivity.java:368) E/AndroidRuntime(13249): at com.example.hello1.hello1.onCreate(hello1.java:31) E/AndroidRuntime(13249): at android.app.Activity.performCreate(Activity.java:5231) E/AndroidRuntime(13249): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087) E/AndroidRuntime(13249): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2148) E/AndroidRuntime(13249): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2233) E/AndroidRuntime(13249): at android.app.ActivityThread.access$800(ActivityThread.java:135) E/AndroidRuntime(13249): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196) E/AndroidRuntime(13249): at android.os.Handler.dispatchMessage(Handler.java:102) E/AndroidRuntime(13249): at android.os.Looper.loop(Looper.java:136) E/AndroidRuntime(13249): at android.app.ActivityThread.main(ActivityThread.java:5001) E/AndroidRuntime(13249): at java.lang.reflect.Method.invoke(Native Method) E/AndroidRuntime(13249): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:785) E/AndroidRuntime(13249): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:601) E/AndroidRuntime(13249): Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Class org.xwalk.core.XWalkCoreWrapper.getBridgeClass(java.lang.String)' on a null object reference E/AndroidRuntime(13249): at org.xwalk.core.XWalkPreferences.setValue(XWalkPreferences.java:106) E/AndroidRuntime(13249): at org.apache.cordova.CordovaWebView.<clinit>(CordovaWebView.java:897) E/AndroidRuntime(13249): ... 16 more {code}

    JIRA | 2 years ago | lvyunxiao
    java.lang.ExceptionInInitializerError
  3. 0

    Impacted Cases ============== Reproduce Test Steps ==================== download crosswalk-cordova-15.43.349.0-x86.zip 1. create a project with activity which inherit from CordovaActivity 2. load url in onCreate() 3. run the project Expected Outcome ================ Cordova works fine Actual Outcome ============== Cordova crashed when launch the project. Please look at the following info: {code}05-20 15:57:27.442: E/AndroidRuntime(2452): java.lang.ExceptionInInitializerError 05-20 15:57:27.442: E/AndroidRuntime(2452): at org.apache.cordova.CordovaActivity.makeWebView(CordovaActivity.java:350) 05-20 15:57:27.442: E/AndroidRuntime(2452): at org.apache.cordova.CordovaActivity.init(CordovaActivity.java:386) 05-20 15:57:27.442: E/AndroidRuntime(2452): at org.apache.cordova.CordovaActivity.init(CordovaActivity.java:378) 05-20 15:57:27.442: E/AndroidRuntime(2452): at com.dengly.example.firstcordova.MainActivity.onCreate(MainActivity.java:36) 05-20 15:57:27.442: E/AndroidRuntime(2452): at android.app.Activity.performCreate(Activity.java:5104) 05-20 15:57:27.442: E/AndroidRuntime(2452): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1080) 05-20 15:57:27.442: E/AndroidRuntime(2452): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2227) 05-20 15:57:27.442: E/AndroidRuntime(2452): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2313) 05-20 15:57:27.442: E/AndroidRuntime(2452): at android.app.ActivityThread.access$600(ActivityThread.java:144) 05-20 15:57:27.442: E/AndroidRuntime(2452): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1317) 05-20 15:57:27.442: E/AndroidRuntime(2452): at android.os.Handler.dispatchMessage(Handler.java:99) 05-20 15:57:27.442: E/AndroidRuntime(2452): at android.os.Looper.loop(Looper.java:152) 05-20 15:57:27.442: E/AndroidRuntime(2452): at android.app.ActivityThread.main(ActivityThread.java:5132) 05-20 15:57:27.442: E/AndroidRuntime(2452): at java.lang.reflect.Method.invokeNative(Native Method) 05-20 15:57:27.442: E/AndroidRuntime(2452): at java.lang.reflect.Method.invoke(Method.java:511) 05-20 15:57:27.442: E/AndroidRuntime(2452): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793) 05-20 15:57:27.442: E/AndroidRuntime(2452): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560) 05-20 15:57:27.442: E/AndroidRuntime(2452): at dalvik.system.NativeStart.main(Native Method) 05-20 15:57:27.442: E/AndroidRuntime(2452): Caused by: java.lang.NullPointerException 05-20 15:57:27.442: E/AndroidRuntime(2452): at org.xwalk.core.XWalkPreferences.setValue(XWalkPreferences.java:107) 05-20 15:57:27.442: E/AndroidRuntime(2452): at org.apache.cordova.CordovaWebView.<clinit>(CordovaWebView.java:905){code} Test Case Source Code ===================== Test Builds =========== Issue Analysis ============== xwalk library was not initialized.

    JIRA | 2 years ago | Hengzhi Wu
    java.lang.ExceptionInInitializerError
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    App which was built by cordova 4.0 crosswalk 15.44.361.0 will crash when launch it. Impacted Cases ============== All Cordova 4.0 test suites. Reproduce Test Steps ==================== 1. {{cordova create foo com.example.foo foo}} 2. {{cd foo; cordova platform add android}} 3. Download cordova-plugin-crosswalk-webview and setting webview config: {{vim cordova-plugin-crosswalk-webview/src/android/xwalk.gradle}} change: "_beta:13+" to ":15.44.361.0" change: maven { url 'https://download.01.org/crosswalk/releases/crosswalk/android/maven2' } to mavenLocal() 4. Install webview plugin with maven:{{mvn install:install-file -DgroupId=org.xwalk -DartifactId=xwalk_core_library -Dversion=15.44.361.0 -Dpackaging=aar -Dfile=<path>/crosswalk-15.44.361.0.aar -DgeneratePom=true}} 4. {{cordova plugin add ../cordova-plugin-crosswalk-webview}} 5. Connect device and run:{{cordova run android}} Expected Outcome ================ cordova app run successfully. Actual Outcome ============== App crashed Test Builds =========== ||Version||Test Date|| Test Device || Result|| |crosswalk 15.43.358.0|2015.06.05| Nexus 4|{color:green}Pass{color}| |crosswalk 15.44.361.0|2015.06.12| Nexus 4|{color:red}Crash{color} | |crosswalk 15.44.362.0|2015.06.13| Nexus 4|{color:red}Crash{color} | |crosswalk 15.44.363.0|2015.06.14| Nexus 4|{color:red}Crash{color} | |crosswalk 15.44.364.0|2015.06.16| Nexus 4|{color:red}Crash{color} | |crosswalk 15.44.365.0|2015.06.19| Nexus 4|{color:red}Crash{color} | Issue Analysis ============== adb logcat: {{W/dalvikvm(10050): threadid=1: thread exiting with uncaught exception (group=0x40f5a930) E/AndroidRuntime(10050): FATAL EXCEPTION: main E/AndroidRuntime(10050): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.foo/com.example.foo.MainActivity}: java.lang.RuntimeException: Failed to create webview. E/AndroidRuntime(10050): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2180) E/AndroidRuntime(10050): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2230) E/AndroidRuntime(10050): at android.app.ActivityThread.access$600(ActivityThread.java:141) E/AndroidRuntime(10050): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1234) E/AndroidRuntime(10050): at android.os.Handler.dispatchMessage(Handler.java:99) E/AndroidRuntime(10050): at android.os.Looper.loop(Looper.java:137) E/AndroidRuntime(10050): at android.app.ActivityThread.main(ActivityThread.java:5041) E/AndroidRuntime(10050): at java.lang.reflect.Method.invokeNative(Native Method) E/AndroidRuntime(10050): at java.lang.reflect.Method.invoke(Method.java:511) E/AndroidRuntime(10050): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793) E/AndroidRuntime(10050): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560) E/AndroidRuntime(10050): at dalvik.system.NativeStart.main(Native Method) E/AndroidRuntime(10050): Caused by: java.lang.RuntimeException: Failed to create webview. E/AndroidRuntime(10050): at org.apache.cordova.CordovaWebViewImpl.createEngine(CordovaWebViewImpl.java:82) E/AndroidRuntime(10050): at org.apache.cordova.CordovaActivity.makeWebViewEngine(CordovaActivity.java:191) E/AndroidRuntime(10050): at org.apache.cordova.CordovaActivity.makeWebView(CordovaActivity.java:187) E/AndroidRuntime(10050): at org.apache.cordova.CordovaActivity.init(CordovaActivity.java:135) E/AndroidRuntime(10050): at org.apache.cordova.CordovaActivity.loadUrl(CordovaActivity.java:209) E/AndroidRuntime(10050): at com.example.foo.MainActivity.onCreate(MainActivity.java:32) E/AndroidRuntime(10050): at android.app.Activity.performCreate(Activity.java:5104) E/AndroidRuntime(10050): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1080) E/AndroidRuntime(10050): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2144) E/AndroidRuntime(10050): ... 11 more E/AndroidRuntime(10050): Caused by: java.lang.reflect.InvocationTargetException E/AndroidRuntime(10050): at java.lang.reflect.Constructor.constructNative(Native Method) E/AndroidRuntime(10050): at java.lang.reflect.Constructor.newInstance(Constructor.java:417) E/AndroidRuntime(10050): at org.apache.cordova.CordovaWebViewImpl.createEngine(CordovaWebViewImpl.java:80) E/AndroidRuntime(10050): ... 19 more E/AndroidRuntime(10050): Caused by: java.lang.NullPointerException E/AndroidRuntime(10050): at org.xwalk.core.XWalkCoreWrapper.initEmbeddedMode(XWalkCoreWrapper.java:110) E/AndroidRuntime(10050): at org.xwalk.core.XWalkPreferences.setValue(XWalkPreferences.java:105) E/AndroidRuntime(10050): at org.crosswalk.engine.XWalkCordovaView.setGlobalPrefs(XWalkCordovaView.java:41) E/AndroidRuntime(10050): at org.crosswalk.engine.XWalkCordovaView.<init>(XWalkCordovaView.java:50) E/AndroidRuntime(10050): at org.crosswalk.engine.XWalkWebViewEngine.<init>(XWalkWebViewEngine.java:56) E/AndroidRuntime(10050): ... 22 more W/ActivityManager( 517): Force finishing activity com.example.foo/.MainActivity D/dalvikvm( 517): GC_FOR_ALLOC freed 771K, 17% free 15212K/18172K, paused 50ms, total 50ms D/overlay ( 159): Set pipe=RGB1 dpy=0; Set pipe=VG0 dpy=0; Set pipe=VG1 dpy=0; D/overlay ( 159): Unset pipe=VG0 dpy=0; Unset pipe=VG1 dpy=0; Unset pipe=RGB1 dpy=0; W/ActivityManager( 517): Activity pause timeout for ActivityRecord{41af7738 u0 com.example.foo/.MainActivity} I/ActivityManager( 517): No longer want com.android.vending (pid 8637): empty for 2193s W/ActivityManager( 517): Scheduling restart of crashed service com.android.vending/com.google.android.finsky.services.DailyHygiene in 5000ms }}

    JIRA | 1 year ago | Hao Yunfei
    java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.foo/com.example.foo.MainActivity}: java.lang.RuntimeException: Failed to create webview.
  6. 0

    Impacted Cases ============== usecase-embedding-android-tests Reproduce Test Steps ==================== 1. Install shared Embedding UseCase app on the device 2. check the UI & enter Animatable XWalkView case 3. exit this case Expected Outcome ================ test case is normal Actual Outcome ============== app crash when exit this case Crash info: E/AndroidRuntime(19897): FATAL EXCEPTION: main E/AndroidRuntime(19897): java.lang.RuntimeException: Unable to destroy activity {org.xwalk.embedded.api.sample/org.xwalk.embedded.api.sample.AnimatableXWalkViewActivity}: java.lang.NullPointerException E/AndroidRuntime(19897): at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:3534) E/AndroidRuntime(19897): at android.app.ActivityThread.handleDestroyActivity(ActivityThread.java:3552) E/AndroidRuntime(19897): at android.app.ActivityThread.access$1200(ActivityThread.java:144) E/AndroidRuntime(19897): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1370) E/AndroidRuntime(19897): at android.os.Handler.dispatchMessage(Handler.java:99) E/AndroidRuntime(19897): at android.os.Looper.loop(Looper.java:152) E/AndroidRuntime(19897): at android.app.ActivityThread.main(ActivityThread.java:5132) E/AndroidRuntime(19897): at java.lang.reflect.Method.invokeNative(Native Method) E/AndroidRuntime(19897): at java.lang.reflect.Method.invoke(Method.java:511) E/AndroidRuntime(19897): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793) E/AndroidRuntime(19897): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560) E/AndroidRuntime(19897): at dalvik.system.NativeStart.main(Native Method) E/AndroidRuntime(19897): Caused by: java.lang.NullPointerException E/AndroidRuntime(19897): at org.xwalk.core.XWalkPreferences.setValue(XWalkPreferences.java:107) E/AndroidRuntime(19897): at org.xwalk.embedded.api.sample.AnimatableXWalkViewActivity.onDestroy(AnimatableXWalkViewActivity.java:53) E/AndroidRuntime(19897): at android.app.Activity.performDestroy(Activity.java:5273) E/AndroidRuntime(19897): at android.app.Instrumentation.callActivityOnDestroy(Instrumentation.java:1110) E/AndroidRuntime(19897): at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:3521) E/AndroidRuntime(19897): ... 11 more Test Case Source Code ===================== Test Builds =========== Issue Analysis ==============

    JIRA | 2 years ago | yang yunlong
    java.lang.RuntimeException: Unable to destroy activity {org.xwalk.embedded.api.sample/org.xwalk.embedded.api.sample.AnimatableXWalkViewActivity}: java.lang.NullPointerException

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.NullPointerException

      Attempt to invoke virtual method 'java.lang.Class org.xwalk.core.XWalkCoreWrapper.getBridgeClass(java.lang.String)' on a null object reference

      at org.xwalk.core.XWalkPreferences.setValue()
    2. org.xwalk.core
      XWalkPreferences.setValue
      1. org.xwalk.core.XWalkPreferences.setValue(XWalkPreferences.java:106)
      1 frame
    3. org.apache.cordova
      CordovaActivity.init
      1. org.apache.cordova.CordovaWebView.<clinit>(CordovaWebView.java:897)
      2. org.apache.cordova.CordovaActivity.makeWebView(CordovaActivity.java:340)
      3. org.apache.cordova.CordovaActivity.init(CordovaActivity.java:376)
      4. org.apache.cordova.CordovaActivity.init(CordovaActivity.java:368)
      4 frames
    4. com.example.hello1
      hello1.onCreate
      1. com.example.hello1.hello1.onCreate(hello1.java:31)
      1 frame
    5. Android Platform
      ActivityThread.main
      1. android.app.Activity.performCreate(Activity.java:5231)
      2. android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1087)
      3. android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2148)
      4. android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2233)
      5. android.app.ActivityThread.access$800(ActivityThread.java:135)
      6. android.app.ActivityThread$H.handleMessage(ActivityThread.java:1196)
      7. android.os.Handler.dispatchMessage(Handler.java:102)
      8. android.os.Looper.loop(Looper.java:136)
      9. android.app.ActivityThread.main(ActivityThread.java:5001)
      9 frames
    6. Java RT
      Method.invoke
      1. java.lang.reflect.Method.invoke(Native Method)
      1 frame
    7. Android
      ZygoteInit.main
      1. com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:785)
      2. com.android.internal.os.ZygoteInit.main(ZygoteInit.java:601)
      2 frames