Caused by: java.lang.ClassNotFoundException: Didn't find class ""on path: DexPathList[[zip file "/da
2017-08-09 11:30
701 查看
错误日志
这个问题导致打包apk后安装到手机上时,直接闪退,打不开,纠结了好久这个问题。。。
参考了https://stackoverflow.com/questions/19523167/android-classnotfoundexception-didnt-find-class-on-path这个上面的回答,问题就出在
I had the same issue for my project.It happened due to the conflict in android support library version between my project and the library project that i added in my project. Put the same version android support library in your project and library projects you included and clean build… Everything will work…
也就是项目中的 support library 的版本与library中的 support library 版本不一致。我项目中的版本是compile ‘com.android.support:appcompat-v7:26.+’,所以我将library中的版本也改成了compile ‘com.android.support:appcompat-v7:26.+’,问题就解决了。记住!!!修改了之后要先clean一下项目,然后再重新运行。
java.lang.RuntimeException: Unable to instantiate application maibai.maibai.com.maibai.StaticApplication: java.lang.ClassNotFoundException: Didn't find class "maibai.maibai.com.maibai.StaticApplication" on path: DexPathList[[zip file "/data/app/com.android.maibai-1/base.apk"],nativeLibraryDirectories=[/data/app/com.android.maibai-1/lib/arm64, /data/app/com.android.maibai-1/base.apk!/lib/arm64-v8a, /vendor/lib64, /system/lib64]] at android.app.LoadedApk.makeApplication(LoadedApk.java:600) at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5144) at android.app.ActivityThread.access$1600(ActivityThread.java:190) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1674) at android.os.Handler.dispatchMessage(Handler.java:111) at android.os.Looper.loop(Looper.java:207) at android.app.ActivityThread.main(ActivityThread.java:5969) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:830) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:720) Caused by: java.lang.ClassNotFoundException: Didn't find class "maibai.maibai.com.maibai.StaticApplication" on path: DexPathList[[zip file "/data/app/com.android.maibai-1/base.apk"],nativeLibraryDirectories=[/data/app/com.android.maibai-1/lib/arm64, /data/app/com.android.maibai-1/base.apk!/lib/arm64-v8a, /vendor/lib64, /system/lib64]] at dalvik.system.BaseDexClassLoader.findCl 4000 ass(BaseDexClassLoader.java:56) at java.lang.ClassLoader.loadClass(ClassLoader.java:511) at java.lang.ClassLoader.loadClass(ClassLoader.java:469) at android.app.Instrumentation.newApplication(Instrumentation.java:993) at android.app.LoadedApk.makeApplication(LoadedApk.java:595) at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5144) at android.app.ActivityThread.access$1600(ActivityThread.java:190) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1674) at android.os.Handler.dispatchMessage(Handler.java:111) at android.os.Looper.loop(Looper.java:207) at android.app.ActivityThread.main(ActivityThread.java:5969) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:830) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:720) Suppressed: java.lang.ClassNotFoundException: maibai.maibai.com.maibai.StaticApplication at java.lang.Class.classForName(Native Method) at java.lang.BootClassLoader.findClass(ClassLoader.java:781) at java.lang.BootClassLoader.loadClass(ClassLoader.java:841) at java.lang.ClassLoader.loadClass(ClassLoader.java:504) ... 12 more Caused by: java.lang.NoClassDefFoundError: Class not found using the boot class loader; no stack trace available
这个问题导致打包apk后安装到手机上时,直接闪退,打不开,纠结了好久这个问题。。。
参考了https://stackoverflow.com/questions/19523167/android-classnotfoundexception-didnt-find-class-on-path这个上面的回答,问题就出在
I had the same issue for my project.It happened due to the conflict in android support library version between my project and the library project that i added in my project. Put the same version android support library in your project and library projects you included and clean build… Everything will work…
也就是项目中的 support library 的版本与library中的 support library 版本不一致。我项目中的版本是compile ‘com.android.support:appcompat-v7:26.+’,所以我将library中的版本也改成了compile ‘com.android.support:appcompat-v7:26.+’,问题就解决了。记住!!!修改了之后要先clean一下项目,然后再重新运行。
相关文章推荐
- Caused by: java.lang.ClassNotFoundException: Didn't find class "XXX" on path: DexPathList[[zip file
- Caused by: java.lang.ClassNotFoundException: Didn't find class "** *** ** **" on path: DexPathList[[zip file "/data/app/*** *** ***-2/base.apk"],nativeLibraryDirectories
- 07-09 07:28:38.350: E/AndroidRuntime(1437): Caused by: java.lang.ClassNotFoundException: Didn't find class "com.example.googleplay.ui.activity.MainActivity" on path: DexPathList[[zip file "/data/app/c
- Caused by: java.lang.ClassNotFoundException: Didn't find class "net.oschina.app.AppContext" on path:
- Caused by: java.lang.ClassNotFoundException: Didn't find class "包名" on path
- java.lang.ClassNotFoundException: Didn't find class "stu.love.neihan.MainActivity" on path: DexPathL
- 报ClassNotFoundException: Didn't find class "...Activity" on path: DexPathList
- java.lang.ClassNotFoundException:Didn't find class "android.os.PersistableBundle" on path 奇葩BUG解决
- eclipse出现java.lang.ClassNotFoundException: Didn't find class "xxx" on path: DexP...解决方案
- java.lang.ClassNotFoundException: Didn't find class "*****Activity" on path: /data/app/*******.apk
- java.lang.ClassNotFoundException: Didn't find class "*****Activity" on path: /data/app/*******.apk
- java.lang.ClassNotFoundException: Didn't find class "*****Activity" on path: /data/app/*******.apk的
- java.lang.ClassNotFoundException: Didn't find class "*****Activity" on path: /data/app/*******.apk
- java.lang.ClassNotFoundException: Didn't find class "*****Activity" on path: /data/app/*******.apk
- Android开发之~java.lang.ClassNotFoundException: Didn't find class "android.view.x" on path: ...
- Caused by: java.lang.ClassNotFoundException: Didn’t find class on path apk Android Studio解决方案
- java.lang.ClassNotFoundException: Didn't find class "android.os.PersistableBundle" on path: DexPathL
- Caused by: java.lang.ClassNotFoundException: Didn't find class ".MainActivity"
- java.lang.ClassNotFoundException: Didn't find class "stu.love.neihan.MainActivity" on path: DexPathL
- Caused by: java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file "/sys