'flutter daemon terminated when I try to launch my app

Just upgraded to v1.1.8 for flutter. Restarted Android studio. Using an emulator. Drop down menu for devices has disappeared and the AVD manager has been greyed out.



Solution 1:[1]

What worked for me is to kill the adb.exe processes in the Task Manager. There were 20 of them and once I killed them all everything started working normally.

Solution 2:[2]

I deleted the flutter folder by mistake. Re-cloning it back and restarting flutter worked for me

Solution 3:[3]

It can be a permission issue. If just in case you're using VSCode then it always tries to search for the devices without sudo command. Check if your flutter command can run without attaching sudo to it (sudo flutter). If it throws some error then there's a permission issue. To solve this, you will need to reinstall the flutter in the low secured directory like /usr etc. Or just change the folder permissions where you have installed the flutter.

Hope this will fix it.

Solution 4:[4]

for me it was my firewall, I was using the COMODO firewall and it was blocking the Flutter Daemon so I just uninstall it and the problem is solved. you can check this article for more solutions => https://www.geeksforgeeks.org/fix-unable-to-locate-adb-within-sdk-in-android-studio/

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 TimSim
Solution 2 Panduranga Rao Sadhu
Solution 3 Yogesh Aggarwal
Solution 4 mmmgreen