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.

Susi Crashes on Network State Changed

See original GitHub issue

This Crash is occurring due to realm NoClassFound, on changing the Network state. I/O Mobile data, Wi-fi. Detected on: Nexus 5 CM13 Android 6.0.1

img_20161003_092010

Log:

10-03 09:14:40.590 32622-32622/org.fossasia.susi.ai E/AndroidRuntime: FATAL EXCEPTION: main
                                                                      Process: org.fossasia.susi.ai, PID: 32622
                                                                      java.lang.RuntimeException: Unable to instantiate receiver io.realm.internal.network.NetworkStateReceiver: java.lang.ClassNotFoundException: Didn't find class "io.realm.internal.network.NetworkStateReceiver" on path: DexPathList[[zip file "/data/app/org.fossasia.susi.ai-1/base.apk"],nativeLibraryDirectories=[/data/app/org.fossasia.susi.ai-1/lib/arm, /data/app/org.fossasia.susi.ai-1/base.apk!/lib/armeabi-v7a, /vendor/lib, /system/lib]]
                                                                          at android.app.ActivityThread.handleReceiver(ActivityThread.java:2750)
                                                                          at android.app.ActivityThread.-wrap14(ActivityThread.java)
                                                                          at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1440)
                                                                          at android.os.Handler.dispatchMessage(Handler.java:102)
                                                                          at android.os.Looper.loop(Looper.java:148)
                                                                          at android.app.ActivityThread.main(ActivityThread.java:5466)
                                                                          at java.lang.reflect.Method.invoke(Native Method)
                                                                          at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
                                                                          at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
                                                                       Caused by: java.lang.ClassNotFoundException: Didn't find class "io.realm.internal.network.NetworkStateReceiver" on path: DexPathList[[zip file "/data/app/org.fossasia.susi.ai-1/base.apk"],nativeLibraryDirectories=[/data/app/org.fossasia.susi.ai-1/lib/arm, /data/app/org.fossasia.susi.ai-1/base.apk!/lib/armeabi-v7a, /vendor/lib, /system/lib]]
                                                                          at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
                                                                          at java.lang.ClassLoader.loadClass(ClassLoader.java:511)
                                                                          at java.lang.ClassLoader.loadClass(ClassLoader.java:469)
                                                                          at android.app.ActivityThread.handleReceiver(ActivityThread.java:2745)
                                                                          at android.app.ActivityThread.-wrap14(ActivityThread.java) 
                                                                          at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1440) 
                                                                          at android.os.Handler.dispatchMessage(Handler.java:102) 
                                                                          at android.os.Looper.loop(Looper.java:148) 
                                                                          at android.app.ActivityThread.main(ActivityThread.java:5466) 
                                                                          at java.lang.reflect.Method.invoke(Native Method) 
                                                                          at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726) 
                                                                          at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616) 
                                                                        Suppressed: java.lang.ClassNotFoundException: Didn't find class "io.realm.internal.network.NetworkStateReceiver" on path: DexPathList[[dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-support-annotations-24.2.1_2f4e12f50b74a0e56083d683ebcd01098f8544c5-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-slice_9-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-slice_8-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-slice_7-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-slice_6-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-slice_5-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-slice_4-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-slice_3-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-slice_2-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-slice_1-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-slice_0-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-retrofit-2.1.0_cf279e13c7581267ec06efb423edffc451b4f5ff-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-realm-annotations-2.0.0_07f36a1f91e6acef3721afd25e88ec47ccc4492f-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-okio-1.8.0_6896106ae3c04439e55501a196384a5ecf60b5b1-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-okhttp-3.3.0_068abd747c7b414410f82e22c0d0b6acbd41650d-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-me.himanshusoni.chatmessageview-chat-message-view-1.0.3_7c27264fb08c446ab7c169a6481f8471c542675d-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-io.realm-realm-android-library-2.0.0_62fb1293c2ee6ddc69320de50e6dbecb6871db03-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-internal_impl-24.2.1_f360842d212d25afcf6d1d16c81608f47758e001-classes.dex", dex file "/data/data/org.fossasia.susi.ai/files/instant-run/dex/slice-internal_impl-24.2.1_ee35e25679ede1b1321

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
Zhuindencommented, Oct 5, 2016

Realm 2.0.1 release fixes this without having to add the broadcast receiver: https://github.com/realm/realm-java/issues/3505#issuecomment-251614137

0reactions
pc-bszabocommented, Oct 5, 2016

Quick and dirty solution : put this into your launcher activity OR Application=>

try { getApplicationContext().getPackageManager().setComponentEnabledSetting(new ComponentName(“your.package.name”,“io.realm.internal.network.NetworkStateReceiver”), PackageManager.COMPONENT_ENABLED_STATE_DISABLED, PackageManager.DONT_KILL_APP); } catch (Exception e) {}

Read more comments on GitHub >

github_iconTop Results From Across the Web

Reading network state - Android Developers
Reading network state ... Android enables apps to learn about dynamic changes in connectivity. Use the following classes to track and respond to...
Read more >
DeFi Protocol SushiSwap Proposes 'Immediate' Action to ...
Developers proposed to divert 100% of fees generated on the platform to Sushi's multisig for one year or until new tokenomics are ...
Read more >
State Patrol - Alcohol Involved in Fatal Crash on Snowy Highway
The victim of the deadly incident has been identified as 39-year-old Sean Stout of Bloomington. The State Patrol says he was driving an...
Read more >
3 Analyzing and Managing System Log Files
SUSE Linux Enterprise Server automatically logs almost everything that happens on the system ... Log files from the Kerberos network authentication system.
Read more >
A twist of fate - NBC News
Susie Van Ryn: You want to believe that accidents happen a lot. ... She is still in a positive signs pull out comatose...
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