Duplicate class a found in modules classes.jar (:gaoesdklibrary:) and classes.jar (gaoesdklibrary.aa

最近集成第三方 “鸟哥笔记”,根据集成文档进行配置:

1、在项目的libs目录放入aar包文件gaoesdklibrary.aar

2、在build.gradle( Module:app )添加依赖代码:

implementation(name: 'gaoesdklibrary', ext: 'aar')

结果项目打包apk的时候,报如下错误:

java.util.concurrent.ExecutionException: java.lang.RuntimeException: Duplicate class a found in modules classes.jar (:gaoesdklibrary:) and classes.jar (gaoesdklibrary.aar)

解决方式:

明显的gaoesdklibrary包重复引用了,很多第三方的集成文档都写的不够严谨,这两种方式显然不能够同时存在!

解决方式要么删除libs文件的gaoesdklibrary.aar包,要么注释implementation(name: 'gaoesdklibrary', ext: 'aar'),

为了操作方便,我注释了build.gradle( Module:app )中的依赖代码

//implementation(name: 'gaoesdklibrary', ext: 'aar')

 

你可能感兴趣的:(错误累积(错题本))