問題描述
每次我在運行我的項目時遇到這個錯誤.我可以做一個清潔然后再次運行,它可以工作.但這不是最佳解決方案.有什么想法嗎?
錯誤:任務 ':android:transformClassesAndResourcesWithProguardForRelease' 的執行失敗.
<塊引用>
java.io.IOException: 無法將 androiduildintermediates ransformsproguard eleasefolders31fmainclasses.jar 重命名為 androiduildintermediates ransformsproguard eleasejars31fclasses.jar
當 SDK、Build Tools 和 Gradle Plugins 的版本不匹配(在兼容性方面)時,會發生此錯誤.解決方案是驗證您是否使用它們的最新版本.gradle 插件放在項目的 build.gradle 文件中.其他版本在模塊的 build.gradle 文件中.對于example,對于SDK 23,您必須使用Build Tools 23.0.1 和gradle plugins version 1.3.1.強>
更改設置后清理項目.(解決了我的問題,再也沒見過.)
參考這個問題
Every time I am getting this error when running my project. I can do a Clean and then Run again, and it works. But it is not an optimal solution. Any ideas?
Error:Execution failed for task ':android:transformClassesAndResourcesWithProguardForRelease'.
java.io.IOException: Failed to rename androiduildintermediates ransformsproguard eleasefolders31fmainclasses.jar to androiduildintermediates ransformsproguard eleasejars31fclasses.jar
This bug happens when the versions of SDK, Build Tools and Gradle Plugins doesn't match (in terms of compatibility). The solution is to verify if you are using the latest versions of them. The gradle plugins are placed in the build.gradle file of the project. Other versions are in the build.gradle file of the module. For example, for SDK 23, you must use the Build Tools 23.0.1 and gradle plugins version 1.3.1.
Clean the project after changing settings. (Solved my problem, and never seen it again.)
refer this question
這篇關于錯誤:任務':android:transformClassesAndResourcesWithProguardForRelease'的執行失敗的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!