Android studio 3.1 rebuild project 每次都能看到变化
Android studio 3.1 rebuild project each time to see the changes
将我的 android 工作室更新到 3.1 版后,我遇到了一个问题:
当我对我的代码进行一些更改时,然后我启动执行,我得到旧的代码执行,直到我重建项目或清理它并重试
那是问题吗 ?
PS:这发生在我的旧项目中,我还没有尝试过新项目
我认为您在 android 工作室中遇到了 BUG,正如 google 通过 Twitter 所声明的那样。
我引用了他们的 3 条推文:
We've identified an error that affects some users upgrading from AS3.0: source files may not automatically rebuild when running or debugging an application. Please add 'Gradle aware make' to pre-launch steps in the Run Configuration or wait for AS3.1.1 hotfix early next week[1/3]
Also around the time of the release, jCenter (a 3rd party repository which hosts many of the libraries used by Android developers) suffered from an outage (read more on http://status.bintray.com/ ). This caused builds to fail and was an unfortunate coincidence. [2/3]
Even though this was something out of our control, we will try to come up with a way to mitigate this in the future. We apologize for any problems and ask all developers to test your projects on our weekly Canary (and soon Beta) versions of Android Studio and file bugs. [3/3]
配上他们的形象:
来源:https://twitter.com/androidstudio/status/981914636739076097
奇怪,但在 Android Studio 3.3.1 中我最近遇到了这个错误。 AS 没有任何变化,但问题出现了。我卸载了 AS,但没有任何改变。我可以恢复到 Git 中的任何提交,但每次都必须重建一个项目才能编译。
所以, 和@Martin Marconcini 的解决方案帮助了我。我添加了 Gradle-aware make
(将 Task
留空)。
在我的例子中,我没有添加 Instant App Provision
因为关闭了 Instant Run
。
更新
几天后我注意到编译时间增加了。当我删除该任务时,AS 再次没有更改构建。于是,我又加了任务
将我的 android 工作室更新到 3.1 版后,我遇到了一个问题:
当我对我的代码进行一些更改时,然后我启动执行,我得到旧的代码执行,直到我重建项目或清理它并重试 那是问题吗 ?
PS:这发生在我的旧项目中,我还没有尝试过新项目
我认为您在 android 工作室中遇到了 BUG,正如 google 通过 Twitter 所声明的那样。
我引用了他们的 3 条推文:
We've identified an error that affects some users upgrading from AS3.0: source files may not automatically rebuild when running or debugging an application. Please add 'Gradle aware make' to pre-launch steps in the Run Configuration or wait for AS3.1.1 hotfix early next week[1/3]
Also around the time of the release, jCenter (a 3rd party repository which hosts many of the libraries used by Android developers) suffered from an outage (read more on http://status.bintray.com/ ). This caused builds to fail and was an unfortunate coincidence. [2/3]
Even though this was something out of our control, we will try to come up with a way to mitigate this in the future. We apologize for any problems and ask all developers to test your projects on our weekly Canary (and soon Beta) versions of Android Studio and file bugs. [3/3]
配上他们的形象:
来源:https://twitter.com/androidstudio/status/981914636739076097
奇怪,但在 Android Studio 3.3.1 中我最近遇到了这个错误。 AS 没有任何变化,但问题出现了。我卸载了 AS,但没有任何改变。我可以恢复到 Git 中的任何提交,但每次都必须重建一个项目才能编译。
所以,Gradle-aware make
(将 Task
留空)。
在我的例子中,我没有添加 Instant App Provision
因为关闭了 Instant Run
。
更新
几天后我注意到编译时间增加了。当我删除该任务时,AS 再次没有更改构建。于是,我又加了任务