FMorschel · GitHub

Describe the bug
If a pub workspace contains flutter packages, we should use flutter pub instead of dart pub.

To Reproduce
Steps to reproduce the behavior:

If you'd like me to create a simple repro, I can.

Expected behavior
Even if the flutter package is not the one being saved (or shown in the IDE), we should detect it and make sure the workspace root pub commands are using flutter instead of dart.

Please complete the following information:

Workspace Environment
Dart Code extension: 3.131.20260304
Flutter extension: 3.131.20260303 (activated)
App: Visual Studio Code
App Host: desktop
Version: win 1.111.0
Workspace type: Dart, Flutter (LSP) (Multiroot)
Workspace name: vendas (Workspace)
Dart (3.11.0): C:\Users\felip_0vh5fa6\.puro\shared\caches\6c0baaebf70e0148f485f27d5616b3d3382da7bf\dart-sdk
Flutter (3.41.2): C:\Users\felip_0vh5fa6\.puro\envs\stable\flutter (SM G780F (android-arm64/android))
Output from 'dart info'

C:\Users\felip_0vh5fa6\.puro\shared\caches\6c0baaebf70e0148f485f27d5616b3d3382da7bf\dart-sdk\bin\dart.exe info

If providing this information as part of reporting a bug, please review the information
below to ensure it only contains things you're comfortable posting publicly.

General info

  • Dart 3.11.0 (stable) (Mon Feb 9 00:38:07 2026 -0800) on "windows_x64"
  • on windows / "Windows 11 Pro" 10.0 (Build 26200)
  • locale is pt-BR

Project info

  • sdk constraint: '^3.10.0'
  • dependencies: async, bloc, brasil_fields, cached_network_image, cloud_firestore, collection, community_charts_flutter, connectivity_plus, convex_bottom_bar, cross_file, currency_text_input_formatter, dartz, device_info_plus, dio, dio_http_cache, direct_select, due_date, equatable, firebase_auth, firebase_core, flutter, flutter_custom_clippers, flutter_easyloading, flutter_keyboard_visibility, flutter_localizations, flutter_signature_pad, flutter_speed_dial, flutter_spinbox, flutter_staggered_grid_view, font_awesome_flutter, grouped_list, image, intl, location, logging, mailer, mask_text_input_formatter, material_design_icons_flutter, package_info_plus, path, path_provider, pdf, percent_indicator, provider, scoped_model, search_cep, share_plus, shared_preferences, sqflite, syncfusion_flutter_datepicker, syncfusion_localizations, time, tutorial_coach_mark, upgrader, url_launcher, validators, wakelock_plus, xml
  • dev_dependencies:
  • elided dependencies: 10

Process info

Memory CPU Elapsed time Command line
0 MB -- dart.exe
0 MB -- dart.exe
0 MB -- dart.exe
0 MB -- dart.exe
0 MB -- dart.exe
0 MB -- dart.exe
0 MB -- dart.exe
0 MB -- dartvm.exe
0 MB -- dartvm.exe
0 MB -- dartvm.exe
Output from 'flutter doctor'

C:\Users\felip_0vh5fa6\.puro\envs\stable\flutter\bin\flutter.bat doctor -v

[!] Flutter (Channel stable, 3.41.2, on Microsoft Windows [Version 10.0.26200.7840], locale pt-BR) [1.263ms]
    • Flutter version 3.41.2 on channel stable at C:\Users\felip_0vh5fa6\.puro\envs\stable\flutter
    ! Warning: `dart` on your path resolves to C:\Users\felip_0vh5fa6\dart\bin\dart.exe, which is not inside your current Flutter SDK checkout at C:\Users\felip_0vh5fa6\.puro\envs\stable\flutter. Consider adding C:\Users\felip_0vh5fa6\.puro\envs\stable\flutter\bin to the front of your path.
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 90673a4eef (3 weeks ago), 2026-02-18 13:54:59 -0800
    • Engine revision 6c0baaebf7
    • Dart version 3.11.0
    • DevTools version 2.54.1
    • Feature flags: enable-web, enable-linux-desktop, enable-macos-desktop, enable-windows-desktop, enable-android, enable-ios, cli-animations, enable-native-assets, 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 (11 Pro 64-bit, 25H2, 2009) [10,6s]
[√] Android toolchain - develop for Android devices (Android SDK version 36.1.0) [14,9s]
    • Android SDK at C:\Users\felip_0vh5fa6\AppData\Local\Android\sdk
    • Emulator version 36.4.9.0 (build_id 14788078) (CL:N/A)
    • Platform android-36.1, build-tools 36.1.0
    • Java binary at: C:\Users\felip_0vh5fa6\AppData\Local\Programs\Android Studio 2\jbr\bin\java
      This is the JDK bundled with the latest Android Studio installation on this machine.
      To manually set the JDK path, use: `flutter config --jdk-dir="path/to/jdk"`.
    • Java version OpenJDK Runtime Environment (build 21.0.6+-13368085-b895.109)
    • All Android licenses accepted.
[√] Chrome - develop for the web [214ms]
    • Chrome at C:\Program Files\Google\Chrome\Application\chrome.exe
[√] Visual Studio - develop Windows apps (Visual Studio Community 2022 17.14.20) [213ms]
    • Visual Studio at C:\Program Files\Microsoft Visual Studio\2022\Community
    • Visual Studio Community 2022 version 17.14.36705.20
    • Windows 10 SDK version 10.0.26100.0
[√] Connected device (5 available) [2,7s]
    • SM G780F (wireless) (mobile) • adb-RX8R30G5WDH-h0vKcv._adb-tls-connect._tcp • android-arm64  • Android 13 (API 33)
    • SM G780F (mobile)            • dev-phone:42541                              • android-arm64  • Android 13 (API 33)
    • Windows (desktop)            • windows                                      • windows-x64    • Microsoft Windows [Version 10.0.26200.7840]
    • Chrome (web)                 • chrome                                       • web-javascript • Google Chrome 143.0.7499.193
    • Edge (web)                   • edge                                         • web-javascript • Microsoft Edge 145.0.3800.82
[√] Network resources [1.145ms]
    • All expected network resources are available.
! Doctor found issues in 1 category.

Read the original on github.com ↗