Gradle构建工具版本从1.2.3升级到1.3.1 [英] Upgrade issue in gradle build tools version from 1.2.3 to 1.3.1
问题描述
我将Gradle构建工具从1.2.3升级到1.3.1,并开始在gradle sync上看到以下错误。我对1.2.3版本没有任何问题。我在gradleVersion 2.3上。无论如何,我可以避免这个错误?
$ b
错误:您的项目包含2个或多个具有相同
标识的模块com.salesforce.android:AndroidCommon at
:AndroidCommon和:AndroidCommon:AndroidCommon。您必须为每个模块使用
不同的标识(名称或组)。
AndroidCommon是我的一个库正在使用。我尝试了Android Studio的1.3和1.4版本。看起来像AS版本无关紧要。
这种错误发生在这些情况下:
- 2个模块具有相同的标识(组+名称)。 检查代码
- 1模块与根项目名称相同
在第一种情况下:
settings.gradle
使用新名称的文件
gradlew clean assemble
在第二种情况下。
- 项目或按照上述步骤操作。
此检查是在gradle-plugin 1.3.x中引入的。
您可以检查代码:
I've upgraded the gradle build tools from 1.2.3 to 1.3.1 and started seeing the following error on gradle sync. I had no issues with 1.2.3 version. I'm on gradleVersion 2.3. Is there anyway I can avoid this error?
Error:Your project contains 2 or more modules with the same identification com.salesforce.android:AndroidCommon at ":AndroidCommon" and ":AndroidCommon:AndroidCommon". You must use different identification (either name or group) for each modules.
AndroidCommon is one of the libraries that I'm using. I tried with versions 1.3 and 1.4 of Android Studio. Seems like the AS version doesn't matter.
This kind of error happens in these cases:
- 2 modules have the same identification (group+name). Check the code
- 1 module has the same name of the root project
In the first case:
- rename one of the modules
- update the
settings.gradle
file with the new name - run
gradlew clean assemble
In the second case.
- rename the root project or follow the steps above.`
This check was introduced with gradle-plugin 1.3.x. You can check the code:
这篇关于Gradle构建工具版本从1.2.3升级到1.3.1的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!