Gradle项目刷新失败:已完成 [英] Gradle project refresh failed: Already finished

查看:257
本文介绍了Gradle项目刷新失败:已完成的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

背景:在这一点上,我一直在与Studio / Gradle争斗一天左右;最初有多个PEBKAC错误(即权限和资源限制)已经解决。不幸的是,谷歌福已经失败了我目前的错误。



这个错误特别发生在尝试完成 ./ gradlew clean 没有成功完成;它在30秒内失败了。

我通过吹掉违规的git repo并重新克隆它,暂时解决了问题。我发现这个错误似乎只发生在一个特定的分支上(例如,切换到x_branch,运行'clean project',接收错误),但还没有弄清楚为什么。试图在接收到错误后切换到另一个分支或返回到主控制器不会将gradle恢复到工作状态;错误仍然存​​在。



错误:
Gradle项目刷新失败:错误:已完成:Android Studio 3.1 // Gradle版本171.4250




$ b p> 我的问题:以前有没有人看过这个错误?

解决方案

重新启动Android Studio:



文件>无效缓存/重新启动为我工作


Background: I've been fighting with Studio/Gradle for a day or so at this point; there were initially multiple PEBKAC errors (namely permissions and resource limits) that have since been resolved. Unfortunately the google-fu has failed me for this current error.

The error specifically occurred attempting to complete ./gradlew clean which did not complete successfully; it failed about 30s in.

I temporarily 'fixed' the problem by blowing away the offending git repo and cloning it anew. I discovered the error seems to occur only on a specific branch (ie, switch to x_branch, run 'clean project,' receive error), but have not yet figured out why. Attempting to switch to another branch or back to master after receiving the error does not revert gradle back to a working state; the error remains.

Error: Gradle project refresh failed: Error: Already finished

System env: Android Studio 3.1 // Gradle version 171.4250

My question(s): Has anyone seen this error before? What does this error mean and how do I prevent it from re-occurring?

解决方案

Restarting Android studio :

File > Invalidate Caches/Restart worked for me

这篇关于Gradle项目刷新失败:已完成的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆