Skip to content

flutter doctor incorrectly warns that Flutter/Dart are outside the SDK when installed via a Scoop junction on Windows #191936

Closed

Description

@SSJ-ZYJ

Steps to reproduce

  1. Install Flutter on Windows using Scoop.

  2. Scoop installs the versioned Flutter SDK and creates a current junction pointing to the currently active version:

D:\Program Files\Scoop\apps\flutter\current
    -> D:\Program Files\Scoop\apps\flutter\3.47.2
  1. Add the Scoop current Flutter directory to PATH:
D:\Program Files\Scoop\apps\flutter\current\bin
  1. Verify the Flutter executable resolved by Windows:
where.exe flutter

Output:

D:\Program Files\Scoop\apps\flutter\current\bin\flutter
D:\Program Files\Scoop\apps\flutter\current\bin\flutter.bat

Verify Dart as well:

where.exe dart

Output:

D:\Program Files\Scoop\apps\flutter\current\bin\dart
D:\Program Files\Scoop\apps\flutter\current\bin\dart.bat
  1. Verify that Scoop's current directory is a Windows Junction:
Get-Item "D:\Program Files\Scoop\apps\flutter\current" | Format-List *

Relevant output:

PSIsContainer : True
Mode          : d-r--l
Target        : {D:\Program Files\Scoop\apps\flutter\3.47.2}
LinkType      : Junction
FullName      : D:\Program Files\Scoop\apps\flutter\current
Attributes    : ReadOnly, Directory, ReparsePoint
  1. Run:
flutter doctor -v

flutter doctor reports that the Flutter and Dart executables are outside the current Flutter SDK checkout even though PATH already points to the Scoop current\bin directory.

This appears related to previous Windows symlink/junction reports such as #124926 and #155474, but it is still reproducible on Flutter 3.47.2 stable with Scoop.

Expected results

flutter doctor should recognize that:

D:\Program Files\Scoop\apps\flutter\current

and:

D:\Program Files\Scoop\apps\flutter\3.47.2

refer to the same Flutter SDK because current is a Windows Junction whose target is the versioned Flutter directory.

No Flutter or Dart PATH warning should be reported.

In particular, Flutter should not suggest adding:

D:\Program Files\Scoop\apps\flutter\current\bin

to the front of PATH, because that directory is already being used.

Actual results

flutter doctor -v reports:

! Warning: `flutter` on your path resolves to D:\Program Files\Scoop\apps\flutter\3.47.2\bin\flutter, which is not inside your current Flutter SDK checkout
  at D:\Program Files\Scoop\apps\flutter\current. Consider adding D:\Program Files\Scoop\apps\flutter\current\bin to the front of your path.

! Warning: `dart` on your path resolves to D:\Program Files\Scoop\apps\flutter\3.47.2\bin\dart, which is not inside your current Flutter SDK checkout at
  D:\Program Files\Scoop\apps\flutter\current. Consider adding D:\Program Files\Scoop\apps\flutter\current\bin to the front of your path.

However, Windows resolves flutter from:

D:\Program Files\Scoop\apps\flutter\current\bin\flutter

as shown by where.exe flutter.

It appears that Flutter resolves the executable path through the Windows Junction to its physical target:

D:\Program Files\Scoop\apps\flutter\3.47.2

while keeping the Flutter SDK checkout path as:

D:\Program Files\Scoop\apps\flutter\current

The two paths refer to the same directory but are treated as different Flutter SDK locations.

This also makes the suggested remediation misleading because current\bin is already the active PATH entry.

Code sample

Code sample
Not applicable. This issue affects the Flutter CLI / flutter doctor path validation and does not require a Flutter application.

Screenshots or Video

Screenshots / Video demonstration

Not applicable.

Logs

Logs
> where.exe flutter
D:\Program Files\Scoop\apps\flutter\current\bin\flutter
D:\Program Files\Scoop\apps\flutter\current\bin\flutter.bat

> where.exe dart
D:\Program Files\Scoop\apps\flutter\current\bin\dart
D:\Program Files\Scoop\apps\flutter\current\bin\dart.bat

Scoop junction:

PSIsContainer : True
Mode          : d-r--l
Target        : {D:\Program Files\Scoop\apps\flutter\3.47.2}
LinkType      : Junction
FullName      : D:\Program Files\Scoop\apps\flutter\current
Attributes    : ReadOnly, Directory, ReparsePoint

Flutter Doctor output

Doctor output
Flutter assets will be downloaded from https://storage.flutter-io.cn. Make sure you trust this source!

[!] Flutter (Channel stable, 3.47.2, on Microsoft Windows [版本 10.0.26200.9168], locale zh-CN) [201ms]
    • Flutter version 3.47.2 on channel stable at D:\Program Files\Scoop\apps\flutter\current
    ! Warning: `flutter` on your path resolves to D:\Program Files\Scoop\apps\flutter\3.47.2\bin\flutter, which is not inside your current Flutter SDK checkout
      at D:\Program Files\Scoop\apps\flutter\current. Consider adding D:\Program Files\Scoop\apps\flutter\current\bin to the front of your path.
    ! Warning: `dart` on your path resolves to D:\Program Files\Scoop\apps\flutter\3.47.2\bin\dart, which is not inside your current Flutter SDK checkout at
      D:\Program Files\Scoop\apps\flutter\current. Consider adding D:\Program Files\Scoop\apps\flutter\current\bin to the front of your path.
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision d3b14c8769 (30 hours ago), 2026-08-26 16:07:51 -0700
    • Engine revision a804b26164
    • Dart version 3.13.2
    • DevTools version 2.60.0
    • Pub download mirror https://pub.flutter-io.cn
    • Flutter download mirror https://storage.flutter-io.cn
    • Feature flags: enable-web, enable-linux-desktop, enable-macos-desktop, enable-windows-desktop, enable-android, enable-ios, cli-animations,
      enable-native-assets, enable-record-use, enable-swift-package-manager, omit-legacy-version-file, enable-lldb-debugging, enable-uiscene-migration
    • If those were intentional, you can disregard the above warnings; however it is recommended to use "git" directly to perform update checks and upgrades.

[✓] Windows Version (Windows 11 or higher, 25H2, 2009) [1,778ms]

[✓] Android toolchain - develop for Android devices (Android SDK version 37.0.0) [1,540ms]
    • Android SDK at D:\System\AppData\Local\Android\Sdk
    • Emulator version 37.1.11.0 (build_id 15917651) (CL:N/A)
    • Platform android-37.0, build-tools 37.0.0
    • ANDROID_HOME = D:\System\AppData\Local\Android\Sdk
    • Java binary at: D:\Program Files\Jetbrains\Android Studio\jbr\bin\java
    • Java version OpenJDK Runtime Environment (build 25.0.2+-15348964-b329.117)
    • All Android licenses accepted.

[✓] Chrome - develop for the web [14ms]
    • Chrome at C:\Program Files\Google\Chrome\Application\chrome.exe

[✗] Visual Studio - develop Windows apps [13ms]
    ✗ Visual Studio not installed; this is necessary to develop Windows apps.

[✓] Proxy Configuration [49ms]
    • HTTP_PROXY is set
    • NO_PROXY is localhost,127.0.0.1,::1
    • NO_PROXY contains localhost
    • NO_PROXY contains ::1
    • NO_PROXY contains 127.0.0.1

[✓] Connected device (3 available) [145ms]
    • Windows (desktop) • windows • windows-x64     • Microsoft Windows [版本 10.0.26200.9168]
    • Chrome (web)      • chrome  • web-javascript • Google Chrome 152.0.7977.65
    • Edge (web)        • edge    • web-javascript • Microsoft Edge 151.0.4129.107

[✓] Network resources [694ms]
    • All expected network resources are available.

! Doctor found issues in 2 categories.

Activity

  1. puneetkukreja98 commented on Aug 28, 2026

    @puneetkukreja98
    Contributor

    @SSJ-ZYJ Check this #115651 (comment) if it helps your case.

    Simliar issues:
    #186763
    #119995
    #115651

  2. added
    waiting for responseThe Flutter team cannot make further progress on this issue until the original reporter responds
    and removed
    in triagePresently being triaged by the triage team
    on Aug 28, 2026
  3. SSJ-ZYJ commented on Aug 28, 2026

    @SSJ-ZYJ
    Author

    @puneetkukreja98 Thanks for the references. I checked the linked issues.

    #115651 appears to be related to Windows path normalization/case sensitivity, which was addressed by #115889.

    #119995 is especially similar to my case: Flutter was also installed via Scoop, with the SDK reported under apps\flutter\current while flutter doctor resolved the executable through the version-specific directory.

    #186763 also contains the same Scoop-related flutter doctor warning on Flutter 3.41.9.

    In my case, the warning is still reproducible on Flutter 3.47.2 stable.

    The important detail is that where.exe flutter and where.exe dart both return paths under:

    D:\Program Files\Scoop\apps\flutter\current\bin
    

    while flutter doctor resolves them through the Junction target:

    D:\Program Files\Scoop\apps\flutter\3.47.2\bin
    

    current is a Windows Junction pointing to 3.47.2, so both paths refer to the same SDK.

    Therefore, this looks very similar to #119995, but the underlying Scoop Junction path comparison issue still appears to be present in the current stable release.

  4. SSJ-ZYJ commented on Aug 28, 2026

    @SSJ-ZYJ
    Author

    Update: I’ve implemented a fix and opened a pull request:

    #191975

    The fix resolves Scoop’s Flutter SDK Junction for the internal path comparison while preserving the logical current path in flutter doctor output. It also falls back to the existing behavior if the SDK root cannot be resolved.

    The PR adds regression tests for Flutter, Dart, Windows directory links, unrelated SDK paths, and unresolved SDK roots.

    Validation completed:

    • 23 FlutterValidator tests passed
    • flutter analyze passed
    • Verified on my Windows Scoop installation: both Flutter and Dart PATH warnings disappeared, while the other doctor checks remained unchanged.
  5. removed
    waiting for responseThe Flutter team cannot make further progress on this issue until the original reporter responds
    on Aug 28, 2026
  6. puneetkukreja98 commented on Aug 31, 2026

    @puneetkukreja98
    Contributor

    Routing this to team-windows for futher investigation.

  7. added
    toolAffects the "flutter" command-line tool. See also t: labels.
    platform-windowsBuilding on or for Windows specifically
    fyi-toolFor the attention of Flutter Tool team
    team-windowsOwned by the Windows platform team
    and removed
    in triagePresently being triaged by the triage team
    on Aug 31, 2026
  8. mattkae commented on Sep 9, 2026

    @mattkae
    Contributor

    Routing this to team-windows for futher investigation.

    This is best put on the tool team, correct, since it's a Flutter doctor issue? I figured someone outside of windows would have a better insight into that review than myself.

  9. removed
    team-toolOwned by Flutter Tool team
    fyi-toolFor the attention of Flutter Tool team
    team-windowsOwned by the Windows platform team
    on Sep 12, 2026
  10. flutter-triage-bot commented on Sep 12, 2026

    @flutter-triage-bot

    Issue is assigned to multiple teams (tool, windows). Please ensure the issue has only one team-* label at a time. Use fyi-* labels to have another team look at the issue without reassigning it.

  11. added
    P2Important issues not at the top of the work list
    triaged-toolTriaged by Flutter Tool team
    on Sep 18, 2026
  12. github-actions commented on Oct 6, 2026

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  13. locked as resolved and limited conversation to collaborators on Oct 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work listplatform-windowsBuilding on or for Windows specificallyteam-toolOwned by Flutter Tool teamtoolAffects the "flutter" command-line tool. See also t: labels.triaged-toolTriaged by Flutter Tool team

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions