完毕:
- 生成一个版本 a.abb
- 使用 bundletool 将 a.abb 转换为 a.apks。
- 将其部署到设备。
问题:
找不到动态功能中的活动。(但在调试中,没关系)
2019-02-25 20:48:58.429 11164-11164/? E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.demo.yang.myapplication, PID: 11164
java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{com.demo.yang.myapplication/com.demo.yang.feature.TestActivity}: java.lang.ClassNotFoundException: Didn't find class "com.demo.yang.feature.TestActivity" on path: DexPathList[[zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/base.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.en.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.es.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.ja.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.ko.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.pt.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.ru.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.vi.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.xxhdpi.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.zh.apk"],nativeLibraryDirectories=[/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/lib/arm64, /system/lib64, /vendor/lib64]]
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2839)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3030)
at android.app.ActivityThread.-wrap11(Unknown Source:0)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1696)
at android.os.Handler.dispatchMessage(Handler.java:105)
at android.os.Looper.loop(Looper.java:164)
at android.app.ActivityThread.main(ActivityThread.java:6938)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:327)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1374)
Caused by: java.lang.ClassNotFoundException: Didn't find class "com.demo.yang.feature.TestActivity" on path: DexPathList[[zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/base.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.en.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.es.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.ja.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.ko.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.pt.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.ru.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.vi.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.xxhdpi.apk", zip file "/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.zh.apk"],nativeLibraryDirectories=[/data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/lib/arm64, /system/lib64, /vendor/lib64]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:93)
at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
at android.app.Instrumentation.newActivity(Instrumentation.java:1180)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2829)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3030)
at android.app.ActivityThread.-wrap11(Unknown Source:0)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1696)
at android.os.Handler.dispatchMessage(Handler.java:105)
at android.os.Looper.loop(Looper.java:164)
at android.app.ActivityThread.main(ActivityThread.java:6938)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:327)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1374)
Suppressed: java.io.IOException: No original dex files found for dex location (arm64) /data/app/com.demo.yang.myapplication-mTCYObuADWrZE6proGE_tA==/split_config.en.apk
at dalvik.system.DexFile.openDexFileNative(Native Method)
at dalvik.system.DexFile.openDexFile(DexFile.java:353)
at dalvik.system.DexFile.<init>(DexFile.java:100)
at dalvik.system.DexFile.<init>(DexFile.java:74)