Flutter doctor is not detecting visual studio - flutter

I just installed flutter SDK on my windows pc and then I ran flutter doctor and I got this.
[✓] Flutter (Channel stable, 3.0.3, on Microsoft Windows [版本 10.0.22000.739], locale zh-TW)
[✗] Visual Studio - develop for Windows
✗ Visual Studio not installed; this is necessary for Windows development.
Download at https://visualstudio.microsoft.com/downloads/.
Please install the "Desktop development with C++" workload, including all of its default components
[✓] VS Code (version 1.68.1)
[✓] Connected device (1 available)
[✓] HTTP Host Availability
! Doctor found issues in 1 category.
But I already got visual studio 2022 installed with "Desktop development with C++" on my pc.
What I have tried:
Switch the channel to Master
Install visual studio 2019 with "Desktop development with C++"
Restarting the PC
Reinstall visual studio 2022 with "Desktop development with C++"

I was in the same situation as you.
I solved the problem by bringing vswhere up to date.
In my environment, the following paths are affected.
C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe
Here is the URL I used for reference
https://github.com/microsoft/vswhere/releases
https://github.com/flutter/flutter/issues/102451

Related

Flutter: minor errors when launching app to Android emulator

When I launch an app to an Android emulator, I get the following two error messages, but the app works fine:
E/SurfaceSyncer( 6710): Failed to find sync for id=0
W/Parcel ( 6710): Expecting binder but got null!
Environment: Windows 11, AMD Ryzen 6000
Flutter doctor output:
[✓] Flutter (Channel stable, 3.3.6, on Microsoft Windows [Version 10.0.22621.674], locale en-AU)
[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.0)
[✓] Chrome - develop for the web
[✗] Visual Studio - develop for Windows
✗ Visual Studio not installed; this is necessary for Windows development.
Download at https://visualstudio.microsoft.com/downloads/.
Please install the "Desktop development with C++" workload, including all of its default components
[✓] Android Studio (version 2021.3)
[✓] VS Code (version 1.72.2)
[✓] Connected device (4 available)
[✓] HTTP Host Availability
No errors occur if I instead launch to Chrome.
Any ideas?
Have you installed Visual Studio? This contains the 'Desktop development with C++' which flutter seems to require. (Visual Studio != Visual Studio Code)

Flutter performing hot restart instead of hot reload

I just updated my flutter folder from 2.15 to 3.0. My app runs fine but there's a big problem: when I do CTRL+S, instead of reload my current page to see the changes, it's restarting my whole app, which is extremely annoying. This didn't happen until the upgrade so thought it was a problem of Flutter 3.0. But I downgraded to the version 2.15 and it keeps restarting instead of reloading.
Here's my "flutter doctor":
[√] Flutter (Channel stable, 2.10.5, on Microsoft Windows [Versión 10.0.19041.264], locale es-AR)
[√] Android toolchain - develop for Android devices (Android SDK version 32.1.0-rc1)
[√] Chrome - develop for the web
[X] Visual Studio - develop for Windows
X Visual Studio not installed; this is necessary for Windows development.
Download at https://visualstudio.microsoft.com/downloads/.
Please install the "Desktop development with C++" workload, including all of its default components
[√] Android Studio (version 2020.3)
[√] Android Studio (version 2021.2)
[√] VS Code (version 1.67.1)
[√] Connected device (3 available)
[√] HTTP Host Availability
I also tried running "flutter clean" and "flutter pub get" but it's the same. It says "Performing hot reload" but it actually performs a full restart. I can't work anymore like this.

Why flutter take so much ram to build the grable build after second time I opened the project

When I create the new file of the flutter project the first time it's run smoothly and no issues occur, when I start these projects again after some period of time, the Gradle build is stuck and so much ram usage by the OpenJDK binary platform. After some time pc crashed.
Task manager screenshot
Here is the flutter doctor's output
[✓] Flutter (Channel stable, 2.10.4, on Microsoft Windows [Version 10.0.22000.556], locale en-US)
[!] Android toolchain - develop for Android devices (Android SDK version 32.1.0-rc1)
✗ cmdline-tools component is missing
Run `path/to/sdkmanager --install "cmdline-tools;latest"`
See https://developer.android.com/studio/command-line for more details.
✗ Android license status unknown.
Run `flutter doctor --android-licenses` to accept the SDK licenses.
See https://flutter.dev/docs/get-started/install/windows#android-setup for more details.
[✓] Chrome - develop for the web
[✗] Visual Studio - develop for Windows
✗ Visual Studio not installed; this is necessary for Windows development.
Download at https://visualstudio.microsoft.com/downloads/.
Please install the "Desktop development with C++" workload, including all of its default components
[✓] Android Studio (version 2021.1)
[✓] IntelliJ IDEA Community Edition (version 2021.3)
[✓] VS Code (version 1.66.2)
[✓] Connected device (4 available)
[✓] HTTP Host Availability
So please tell me how do I fix it?

Flutter SDK got Permission deny in Parallels win10?

SDK path c:\sdk\flutter\bin
Project path C:\work\AutoDatas3\UI\auto_datas
I open the cmd with admin , an cd C:\work\AutoDatas3\UI\auto_datas
flutter run GOT:
flutter pub get:
拒绝访问:Permission Deny
Flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 2.5.2, on Microsoft Windows [Version 10.0.21292.1000],
locale zh-CN)
[X] Android toolchain - develop for Android devices
X Unable to locate Android SDK.
Install Android Studio from: https://developer.android.com/studio/index.html
On first launch it will assist you in installing the Android SDK components.
(or visit https://flutter.dev/docs/get-started/install/windows#android-setup for detailed instructions).
If the Android SDK has been installed to a custom location, please use
flutter config --android-sdk to update to that location.
[X] Chrome - develop for the web (Cannot find Chrome executable at .\Google\Chrome\Application\chrome.exe)
! Cannot find Chrome. Try setting CHROME_EXECUTABLE to a Chrome executable.
[X] Visual Studio - develop for Windows
X Visual Studio not installed; this is necessary for Windows development.
Download at https://visualstudio.microsoft.com/downloads/.
Please install the "Desktop development with C++" workload, including all of its default components
[!] Android Studio (not installed)
[√] Connected device (2 available)
! Doctor found issues in 4 categories.
Just delete .package file which created by macos

Flutter error after running Flutter Doctor

I use flutter to develop windows desktop programs, I installed visual studio 2019 enterprise, fully installed, more than 50G. I just installed the part that can change the path on the D drive. But after executing flutter doctor, why does the following prompt appear?
error:
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel dev, 1.23.0-7.0.pre, on Microsoft Windows [Version 10.0.18363.1082], locale zh-CN)
[!] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
! Some Android licenses not accepted. To resolve this, run: flutter doctor --android-licenses
[!] Visual Studio - develop for Windows (Visual Studio Enterprise 2019 16.0.0)
X The current Visual Studio installation is incomplete. Please reinstall Visual Studio.
[√] Android Studio (version 4.0)
[!] IntelliJ IDEA Community Edition (version 2019.3)
X Flutter plugin not installed; this adds Flutter specific functionality.
X Dart plugin not installed; this adds Dart specific functionality.
[√] IntelliJ IDEA Ultimate Edition (version 2018.1)
[√] Connected device (1 available)
! Doctor found issues in 3 categories.
That specific error message from doctor means that the vswhere tool is reporting false for the isComplete property. This means there is an issue with your Visual Studio installation (or at least, Microsoft's tooling believes there is).