问题
I'm developing an Android app in Android Studio and today suddenly it doesn't compile when I press the "Run" button. The error is this:
Error:Execution failed for task ':app:packageInstantRunResourcesDebug'. Java heap space
I've tried cleaning the project and rebuilding it but it didn't work.
回答1:
I have tried many solutions but finally, this helped me to solve this problem : -
distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.1-all.zip
use this line in your "gradle-wrapper.properties". hope it helps others too.
来源:https://stackoverflow.com/questions/48141536/android-studio-error-java-heap-space