Gradle sync failed on android studio 4.0 [duplicate]

瘦欲@ 提交于 2020-06-27 16:38:21

问题


After upgrading my android project to classpath 'com.android.tools.build:gradle:4.0.0' and distributionUrl=https\://services.gradle.org/distributions/gradle-6.1.1-all.zip

I found this error

Gradle sync failed: Cause: org/gradle/api/internal/java/usagecontext/LazyConfigurationUsageContext

my project details is:

compileSdkVersion 29

ndkVersion "21.1.6352462"

minSdkVersion 21

targetSdkVersion 29

How I can solve this problem, on android studio 4.0?


回答1:


Switch to gradle version 5.6.4. LazyConfigurationUsageContext doesn't have support in gradle versions 6.0+.



来源:https://stackoverflow.com/questions/62146334/gradle-sync-failed-on-android-studio-4-0

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!