Android Studio中的Gradle构建失败(无法从缓存读取testArtifacts.bin) [英] Gradle Build Failed in Android Studio (Cannot read testArtifacts.bin from cache)
本文介绍了Android Studio中的Gradle构建失败(无法从缓存读取testArtifacts.bin)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
代码中没有错误.但是构建失败并显示以下错误:
There is no error in the code. But the build fails with the following error:
Error:Could not read entry ':app:packageDebug' from cache taskArtifacts.bin (/Users/sibidharan/Developer/Android Dev/Karpagam/.gradle/2.10/taskArtifacts/taskArtifacts.bin).
> java.io.EOFException (no error message)
我正在OS X 10.11.3上使用Android Studio 2.0 Preview 9
I am using Android Studio 2.0 Preview 9 on OS X 10.11.3
推荐答案
删除项目本地的.gradle
文件夹对我来说是成功的.然后在下一个版本中重新创建它,一切都很好.
Removing the project-local .gradle
folder did it for me. It was then recreated during the next build and all was fine again.
更新:
此答案很有帮助.
Gradle 缓存位于
- 在Windows上:%USER_HOME%.gradle/caches
- 在Mac/Unix上:$ HOME/.gradle/caches/
您可以浏览到这些目录并手动将其删除或运行
You can browse to these directory and manually delete it or run
rm -rf $HOME/.gradle/caches/
在Unix或OS X系统上.
on Unix or OS X system.
这篇关于Android Studio中的Gradle构建失败(无法从缓存读取testArtifacts.bin)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文