Flutter device daemon #1 error - Can't run any apps on mobile device

8,604

I know it is bit late but this has resolved the issue. Make sure , you have downloaded the following-: flutter git

Next , is to add the following in user Path Variables [ Environment Variables<Users<Path ]

C:\src\flutter\bin

Now, add them in System Path Variables. [Environment Variables< System< Path]

  1. C:\Program Files\Git\cmd // git path

  2. C:\Windows\System32\WindowsPowerShell\v1.0\
    // power shell path as if you not set this it will show error like error powershell executable not found

  3. C:\Windows\System32

Share:
8,604
Bisclavret
Author by

Bisclavret

Updated on December 12, 2022

Comments

  • Bisclavret
    Bisclavret over 1 year

    I am not able to run any apps at all at present, as my setup is giving me the following error:

    Flutter device daemon
      Flutter device daemon #1: process exited during startup. Exit code: 1, stderr:
      'where' is not recognized as an internal or external command,
      operable program or batch file.
    

    This manifests itself by showing my device list as constantly "loading..." and never finding my device.

    Flutter doctor -v from command line:

    enter image description here

    Flutter doctor -v from Gitbash, because I have git, despite the path error.

    enter image description here

    Git is located at X:\flutter\bin\mingit\cmd\git.exe which is included in my PATH variable.

    I have tried reinstalling the SDK, Flutter and Android Studio from scratch to resolve this so far, but I can't shake it.

    Hope there is a pro out there that can help.

    • ישו אוהב אותך
      ישו אוהב אותך almost 5 years
      'where' is not recognized as an internal or external command, it seems that when you running the flutter command it try to located a file with where command. I don't think there is a where command in Windows, except when you have a cygwin installed. Does this problem is encountered after you upgrade the flutter?
    • Bisclavret
      Bisclavret almost 5 years
      Hi mate, thank you for your response. Flutter is fully upgraded and I even reinstalled it from scratch to try and resolve this error. The error is still there. Does gitbash use cygwin? This is ringing a bell, wonder if having this installed is causing all my issues?
    • ישו אוהב אותך
      ישו אוהב אותך almost 5 years
      I've searched for gitbash and cygwin love-hate relationship but none found anything related with your problem. But probably the gitbash messing your flutter because it add its path to your environment. Does uninstalling gitbash can solve your problem? Have you test it?
    • Bisclavret
      Bisclavret almost 5 years
      I will test it tonight when I get home, thank you for the advice
    • ישו אוהב אותך
      ישו אוהב אותך almost 5 years
      Hoping that you'll solved the problem tonight ;)
    • Bisclavret
      Bisclavret almost 5 years
      I uninstalled git completely from my machine, then reinstalled it from scratch. Tested again and I am getting exactly the same error. Have now reinstalled Android Studio, Flutter, SDK, and Git and nothing has changed at all :(
    • Bisclavret
      Bisclavret almost 5 years
      I have noticed that if I run flutter doctor from c:\windows\system32 it seems to work fine. If I run it from anywhere else I get the 'where' is not recognised error..... this could be the key, but I still don't know what could be wrong.
  • MichaelMao
    MichaelMao over 2 years
    In my case, it was the dartSDK setting path not right, correct the SDK path works for me :]