[英]Android Studio is not detecting code changes when deploy
When I change the code, change is not reflected to the APK or to the debugged app.当我更改代码时,更改不会反映到 APK 或调试的应用程序中。 What I did so far:
到目前为止我做了什么:
I am on Macos 12.6.2.我在 Macos 12.6.2 上。 There is a known issue with the MacOs: Incremental updates are not applied due to an issue with Gradle file watching on projects saved under /System/Volumes/Data But my project is not under this folder.
MacO 有一个已知问题:增量更新未应用,因为 Gradle 文件监视保存在 /System/Volumes/Data下的项目 但我的项目不在此文件夹下。
I suspect that this problem started after the Macos update.我怀疑这个问题是在 Macos 更新后开始的。 It sometimes works for the first time but does not work after that.
它有时第一次工作,但之后就不起作用了。
Any idea how to fix it?知道如何解决吗?
Nelson Osacky, Gradle Engineer helped me in identifying the issue. Nelson Osacky,Gradle 工程师帮助我确定了问题。 He pointed me to the plugins used in the project.
他向我指出了项目中使用的插件。 Thanks to him!
感谢他!
'gradle.plugin.com.github.sgtsilvio.gradle:android-retrofix:0.4.1' plugin was the root cause for the issue. 'gradle.plugin.com.github.sgtsilvio.gradle:android-retrofix:0.4.1' 插件是问题的根本原因。 When I removed it, everything worked fine.
当我删除它时,一切正常。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.