my android studios started freezing up on me so I killed the task using task manager and when I reopened android studio I got this error:
Error:Failed to complete Gradle execution. Cause: Gradle build daemon disappeared unexpectedly (it may have been killed or may have crashed)
I tried cleaning and rebuilding the gradle and closing out and reopening android but it doesn't go away. The main answers on stack overflow seem to have outdated answers to click on things that are not there anymore such as Settings-->Gradle-->GradleVM options
.
The Gradle daemon is a background process that stays alive between builds, caching both data and code. Most recent versions of Gradle automatically start a Gradle daemon whenever you run from the command prompt.
In Android Studio, go to File > Project Structure. Then select the "project" tab on the left. Your Gradle version will be displayed here.
org.gradle.jvmargs - specifies jvmargs used for daemon process. You want to set high enough memory limit to fix dex in Gradle process, so minimum configuration here is -Xmx2g , while 3-4 gigabytes won't hurt either.
As outlined here: https://developer.android.com/studio/intro/studio-config.html
To change the VM heap size do the following: 1. Help > Edit Custom VM Options 2. Add the line
-XmxheapSize
, where heapSize is the size you want. ie.
-Xmx2g
for 2 gigs
i solved it from information issue tracker it happen in android 3.0 canary 4
android.enableAapt2=false
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With