Android Studio Gradle build failed. Error:Cause: peer not authenticated

前端 未结 23 1877
离开以前
离开以前 2020-12-03 04:54

I have already created one project and gradle sync worked successfully.

When I try to create another project it fails and gives the error message that



        
23条回答
  •  青春惊慌失措
    2020-12-03 05:06

    This was the solution that worked for me. Posting here in case it helps someone.

    Gradle version was not correct in project build.gradle file.

    I had

    classpath 'com.android.tools.build:gradle:1.0.0'
    

    but this needed to be

    classpath 'com.android.tools.build:gradle:2.1.0'
    

    Note:
    This should be updated to the newest version of gradle tools which can be found here Android Studio also recommends the latest plugin version.

提交回复
热议问题