Android studio - Failed to complete gradle execution - error in opening zip file

后端 未结 15 2155
伪装坚强ぢ
伪装坚强ぢ 2020-11-29 04:21

I\'m new to android development and android studio IDE.

I\'ve checked-out a project from bitbucket and when I try to compile it I get the following error:

相关标签:
15条回答
  • 2020-11-29 04:43

    Simply change distributionUrl to latest like this:

    distributionUrl=https\://services.gradle.org/distributions/gradle-6.1-all.zip
    

    It will download all necessary gradle files and your good to go.

    0 讨论(0)
  • 2020-11-29 04:49

    I fixed this issue by...

    • Going to Settings... > Gradle
    • Selecting "Use local Gradle distribution."
    • Pointed it to my Gradle zip file: home/kersting/.gradle/wrapper/dists/gradle-1.12-all/6vpvhqu0efs1fqmqr2decq1v12/gradle-1.12

    It should be something similar for you if you downloaded Gradle which you should have when you downloaded Android Studio. Be careful, the .gradle file may be hidden. I found it through the terminal, but "ls" didn't reveal it.

    0 讨论(0)
  • 2020-11-29 04:52

    For me the solution to this error was to change the gradle wrapper version in ../gradle/wraper/gradle-wrapper.properties to a different/newer version.. I used:

    distributionUrl=https://services.gradle.org/distributions/gradle-2.14.1-all.zip

    Then call:

    ./gradlew --refresh-dependencies

    This tells the wrapper to point to a new version and re-download all required dependencies. I suspect the error for me was caused by an interrupted download when first building the relevant project.

    0 讨论(0)
提交回复
热议问题