gpt4 book ai didi

android - Gradle 构建失败,新的 Gradle 3.0.0 和 Android Studio 3``

转载 作者:塔克拉玛干 更新时间:2023-11-02 20:07:08 25 4
gpt4 key购买 nike

因此,我尝试使用新版本 3 的 Android Studio 从头开始​​一个新项目。一切正常,直到它尝试构建项目。然后我收到此错误消息:

Error:Unable to find method 'org.gradle.tooling.model.gradle.GradleBuild.getIncludedBuilds()Lorg/gradle/tooling/model/DomainObjectSet;'.
Possible causes for this unexpected error include:<ul><li>Gradle's dependency cache may be corrupt (this sometimes occurs after a network connection timeout.)
<a href="syncProject">Re-download dependencies and sync project (requires network)</a></li><li>The state of a Gradle build process (daemon) may be corrupt. Stopping all Gradle daemons may solve this problem.
<a href="stopGradleDaemons">Stop Gradle build processes (requires restart)</a></li><li>Your project may be using a third-party plugin which is not compatible with the other plugins in the project or the version of Gradle requested by the project.</li></ul>In the case of corrupt Gradle processes, you can also try closing the IDE and then killing all Java processes.

单击任一解决方案都不能避免再次失败。我什至清空了我的 gradle 主文件夹,但无济于事。知道为什么这在一个只有基本模板的全新项目上会失败吗?

最佳答案

如果您将 Android Studio 3(resp.3.0.1)安装到旧版本的同一文件夹中,就会发生这种情况。

只需重命名(或删除)旧文件夹,然后解压并重新安装。

关于android - Gradle 构建失败,新的 Gradle 3.0.0 和 Android Studio 3``,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44068642/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com