迁移到androidx后,出现ClassNotFoundException

时间:2019-01-27 17:40:10

标签: java android classnotfoundexception androidx

将我的应用迁移到androidx之后,我在Google Play开发者控制台中崩溃了。 崩溃仅限于Android Pie设备

这是堆栈跟踪。     java.lang.RuntimeException:

  at android.app.ActivityThread.installProvider (ActivityThread.java:6590)

  at android.app.ActivityThread.installContentProviders (ActivityThread.java:6115)

  at android.app.ActivityThread.handleBindApplication (ActivityThread.java:6021)

  at android.app.ActivityThread.access$1300 (ActivityThread.java:207)

  at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1748)

  at android.os.Handler.dispatchMessage (Handler.java:106)

  at android.os.Looper.loop (Looper.java:193)

  at android.app.ActivityThread.main (ActivityThread.java:6863)

  at java.lang.reflect.Method.invoke (Method.java)

  at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:537)

  at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:858)
Caused by: java.lang.ClassNotFoundException: 

  at dalvik.system.BaseDexClassLoader.findClass (BaseDexClassLoader.java:169)

  at java.lang.ClassLoader.loadClass (ClassLoader.java:379)

  at java.lang.ClassLoader.loadClass (ClassLoader.java:312)

  at android.app.AppComponentFactory.instantiateProvider (AppComponentFactory.java:121)

  at android.support.v4.app.CoreComponentFactory.instantiateProvider (CoreComponentFactory.java:62)

  at android.app.ActivityThread.installProvider (ActivityThread.java:6574)

  at android.app.ActivityThread.installContentProviders (ActivityThread.java:6115)

  at android.app.ActivityThread.handleBindApplication (ActivityThread.java:6021)

  at android.app.ActivityThread.access$1300 (ActivityThread.java:207)

  at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1748)

  at android.os.Handler.dispatchMessage (Handler.java:106)

  at android.os.Looper.loop (Looper.java:193)

  at android.app.ActivityThread.main (ActivityThread.java:6863)

  at java.lang.reflect.Method.invoke (Method.java)

  at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:537)

  at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:858)

我认为这与

有关
  at android.support.v4.app.CoreComponentFactory.instantiateProvider (CoreComponentFactory.java:62)

为什么在旧命名空间中会调用此代码?

我无法在本地重现崩溃。

0 个答案:

没有答案