首页 文章

无法合并dex Ionic 3

提问于
浏览
2

上次我成功构建但是在添加了我无法构建的页面数量之后,我确实搜索了很多错误,但没有任何对我有用 . 例如, added and removed the platformionic cordova cleanionic cordova build 等...

运行后遇到错误 - ionic cordova build android

出了什么问题:任务执行失败' :app:transformDexArchiveWithExternalLibsDexMergerForD ebug’. java.lang.RuntimeException:java.lang.RuntimeException:com.android.builder.de xing.DexArchiveMergerException:无法合并dex

尝试:使用--stacktrace选项运行以获取堆栈跟踪 . 使用--info或--debug选项运行以获取更多日志输出 .

https://help.gradle.org获得更多帮助

在7s Build 失败

IOnic Info:

cli包:(C:\ Users \ ITSERV \ AppData \ Roaming \ npm \ node_modules)

@ ionic / cli-utils:1.19.2 ionic(离子CLI):3.20.0全局包:

cordova(Cordova CLI):8.0.0本地包:

@ ionic / app-scripts:3.1.8 Cordova平台:android 7.0.0 Ionic Framework:ionic-angular 3.9.2系统:

节点:v6.11.2 npm:3.10.10操作系统:Windows 7

Thanks in advance!

5 回答

  • 1

    我通过简单地运行此命令然后构建项目来解决此问题 . 不要像升级Gradle或谷歌套餐等那样复杂的答案 .

    cordova clean android 
     ionic cordova build android
    
  • 1

    是什么帮助我运行:

    cordova clean
    
  • 0

    我在我的应用程序中使用谷歌 Map 插件后,我确实在这个问题上挣扎2天,我想这是因为谷歌播放服务冲突,我通过使用此命令安装最新的等级版本来解决它 . 希望它能帮助其他任何人面对这个问题

    ionic cordova plugin add cordova-android-play-services-gradle-release
    
  • 18

    我解决了

    Cordova Clean Android
    Cordova Build Android
    
  • 4

    我有同样的问题

    (无法合并dex Ionic)

    当我创建Ionic应用程序时 . 当我运行应用程序时

    11s Build 失败37个可操作的任务:3个被执行

    发生了错误 . 首先,我使用以下解决方案,但它对我不起作用,但我认为它适用于另一个 .

    configurations.all {
        resolutionStrategy {
           force 'com.android.support:support-v4:26.1.0'
        } 
    }
    

    最后,这有助于我克服未能构建应用程序的问题 .

    cordova clean android
    ionic cordova build android
    ionic cordova run android (To re-launch the app)
    

相关问题