电脑环境:windows 10
Android Stuido 版本2.3.1
今天 Android Stuido遇到下面这个问题
Error:Failed to open zip file.
Gradle’s dependency cache may be corrupt (this sometimes occurs after a network connection timeout.)
Re-download dependencies and sync project (requires network)
后通过下面的方法解决掉问题:
具体参考:
http://stackoverflow.com/questions/38442901/gradles-dependency-cache-may-be-corrupt-this-sometimes-occurs-after-a-network
具体流程如下,其实看上面链接即可:
down vote
Watch the Tutorial https://www.youtube.com/watch?v=u92_73vfA8M
or
follow steps :
Go to any browser
type gradle and press enter
you can specify any version you want after the
gradle keyword
i am downloading gradle 3.3
https://services.gradle.org/distributions click on this link which is in description directly if you want
click on gradle 3.3 all.zip
wait for the download to complete
once the download is complete extract the file to the location
c://user/your pc name /.gradle/wrapper/dists
wait till extraction it takes 5 mins to complete
Now open your project in android studio
9.go to file > settings >bulid ,exec,deployment > gradle
now change use default gradle to
use local gradle distributn
select the location where you had extracted gradle 3.3.zip
C:\Users\your pc name.gradle\wrapper\dists\gradle-3.3
click on OK
Now build starts again and
you can see now the build is successful and error is resolved
2017年4月16日