skip to Main Content

I’m getting this warning after using "Flutter Doctor" command after the installation of Dart using brew tap dart-lang/dart on MacOS Big Sur

Flutter (Channel stable, 3.7.0, on macOS 11.7.2 20G1020 darwin-x64,
locale
en-GB)
! Warning: dart on your path resolves to
/usr/local/Cellar/dart/2.19.1/libexec/bin/dart, which is not inside your
current Flutter SDK checkout at /Users/puneet/development/flutter.
Consider adding /Users/puneet/development/flutter/bin to the front of your
path.

Can you anyone tell me how can i resolve this issue?

I’m trying avoid this warning and run a code on android studio developed on flutter framework.

9

Answers


  1. Here is how I solve this problem
    My dart path on environmental variable was look like (Both user and system variable)

    C:srcdart-sdkbin
    Now I change it to
    C:srcdart-sdkbindart.exe
    and the problem resolved.

    Login or Signup to reply.
  2. The Flutter framework also contains Dart. So, if you already installed Dart separately on your OS, remove Dart and its Path from your system. You should have only one Path that is: /Users/puneet/development/flutter/bin

    Login or Signup to reply.
  3. I resolve this warning by just uninstalling the dart sdk using this command –

    brew uninstall dart
    

    Since dart sdk already comes with flutter installation, you need not to install it seperately.

    Login or Signup to reply.
  4. SOLVED

    when you update your flutter to the latest version this warning comes in your flutter doctor output:-

    IMAGE OF WARNING

    for solving this just go and open .zshrc and after that check your flutter bin path is like this:-

    IMAGE OF PATH

    change your path into this:-

    IMAGE OF PATH

    and then run flutter doctor again… PROBLEM SOLVED ☺️

    ERROR SOLVED

    Login or Signup to reply.
  5. Check your environment variable,if dart path exist remove it.
    Because dart executable exist in flutter and dart-sdk also.Add only path flutter bin.It work fine for me.

    Login or Signup to reply.
  6. It happens because of case sensitive. You can check like that

    which flutter
    

    If result is like that
    /users/***/developments/flutter/bin/flutter"

    export path like that

    export PATH=/Users/***/developments/flutter/bin:$PATH
    
    Login or Signup to reply.
  7. I encountered the same issue.

    The problem was that I didn’t realise it was case-sensitive. The path in my .zshrc was in lowercase, but my Development folder started with a capital D.

    I changed my folder name from Development to development, and everything worked fine.

    I hope this helps!

    Login or Signup to reply.
  8. New name package..
    https://formulae.brew.sh/formula/dart-sdk

    brew install dart-sdk
    
    Login or Signup to reply.
  9. Here a solution:

    export PATH="/Users/puneet/development/flutter/bin:$PATH"

    where "/Users/puneet/development/flutter/bin" is in your message from:

    flutter doctor

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search