Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Flutter error Unable to start the daemon process

My flutter project is run smoothly in my old laptop. But when I use my new laptop, my flutter project can't run in debug mode.

This error

FAILURE: Build failed with an exception.


* What went wrong:

Unable to start the daemon process.

This problem might be caused by incorrect configuration of the daemon.

For example, an unrecognized jvm option is used.

Please refer to the User Manual chapter on the daemon at https://docs.gradle.org/5.6.2/userguide/gradle_daemon.html

Process command line: C:\Program Files (x86)\Java\jre1.8.0_221\bin\java.exe -Xmx1536M -Dfile.encoding=windows-1252 -Duser.country=US -Duser.language=en -Duser.variant -cp C:\Users\ajoris\.gradle\wrapper\dists\gradle-5.6.2-all\9st6wgf78h16so49nn74lgtbb\gradle-5.6.2\lib\gradle-launcher-5.6.2.jar org.gradle.launcher.daemon.bootstrap.GradleDaemon 5.6.2

Please read the following process output to find out more:

-----------------------

Error occurred during initialization of VM

Could not reserve enough space for 1572864KB object heap

Picked up JAVA_TOOL_OPTIONS: -Djava.vendor="Sun Microsystems Inc."


* Try:

Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

Is there something missing in the settings on my new laptop? I tried to clean project, upgrade flutter but always fail. Sorry for new

like image 778
Bertho Joris Avatar asked Mar 02 '23 14:03

Bertho Joris


2 Answers

What actually worked for me is, In windows 10 just turn off your mobile hotspot and run the app again. I think it's a glitch/bug in windows 10.

like image 139
Najam Ul Saqib Avatar answered Mar 05 '23 03:03

Najam Ul Saqib


The solution to this problem is deactivating windows hotspot before running build or app compilation.

Don't delete anything or file, just build the app with mobile hotspot turned off.'

its a windows 10 bug that start without any reason. i refreshed my windows and this started

Flutter or Android Applications

like image 21
Okonkwo Clovis Saintiano Avatar answered Mar 05 '23 04:03

Okonkwo Clovis Saintiano