我正在学习如何使用凌空,但每次我构建我的项目时它都会向我显示此错误。我无法找到适合我的解决方案

时间:2018-04-08 05:36:17

标签: android xml

错误:任务':app:transformDexArchiveWithExternalLibsDexMergerForDebug'执行失败。

  

java.lang.RuntimeException:com.android.builder.dexing.DexArchiveMergerException:无法合并dex

这是我添加到我的gradle中的依赖项

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    implementation 'com.android.support:appcompat-v7:26.1.0'
    implementation 'com.android.support.constraint:constraint-layout:1.0.2'
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'com.android.support.test:runner:1.0.1'
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'
    compile 'com.mcxiaoke.volley:library-aar:1.0.0'
    compile fileTree(dir: 'libs', include: ['*.jar'])
    compile 'com.android.support:appcompat-v7:26.1.0'
    compile 'com.android.volley:volley:1.0.0'
}

1 个答案:

答案 0 :(得分:0)

不推荐使用

> dput(head(theta)) c(0.772925310069695, 0.853900654707104, 0.291106897871941, 0.114210048923269, 0.257764941081405, 0.0881731726694852) > dput(head(random_data_vector)) c(0, 0, 0, 0, 0, 0) ,不要使用2个库进行排球。     仅限com.mcxiaoke.volley:library-aar使用     你也和appcompat lib发生了冲突。  使用这个

**compile 'com.android.volley:volley:1.1.0'**

并删除

 implementation 'com.android.support:appcompat-v7:26.1.0'

并在 compile 'com.android.support:appcompat-v7:26.1.0'

中添加此内容
Build.gradle