Repository navigation
Windows 7 desktop, flutter doctor crash #40238
Copy link
Copy link
Closed
Labels
a: desktopRunning on desktopRunning on desktopc: crashStack traces logged to the consoleStack traces logged to the consoleplatform-windowsBuilding on or for Windows specificallyBuilding on or for Windows specificallyt: flutter doctorProblem related to the "flutter doctor" toolProblem related to the "flutter doctor" tooltoolAffects the "flutter" command-line tool. See also t: labels.Affects the "flutter" command-line tool. See also t: labels.
Description
Installed flutter on windows 7 x64 sp1, enabled flutter desktop development, installed visual studio 2019, got this:
flutter doctor -v
[√] Flutter (Channel master, v1.10.2-pre.36, on Microsoft Windows [Version 6.1.7601], locale ru-RU)
• Flutter version 1.10.2-pre.36 at C:\flutter
• Framework revision 32c946f31b (6 hours ago), 2019-09-10 20:49:27 -0700
• Engine revision 7ea9884ab0
• Dart version 2.5.0 (build 2.5.0-dev.4.0 be66176534)
[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/setup/#android-setup for detailed instructions).
If the Android SDK has been installed to a custom location, set ANDROID_HOME to that location.
You may also want to add it to your PATH environment variable.
[☠] Visual Studio - develop for Windows (the doctor check crashed)
X Due to an error, the doctor check did not complete. If the error message below is not helpful, please let us know
about this issue at https://github.com/flutter/flutter/issues.
X type 'String' is not a subtype of type 'bool'
• #0 VisualStudio.isPrerelease (package:flutter_tools/src/windows/visual_studio.dart:40:7)
#1 VisualStudioValidator.validate (package:flutter_tools/src/windows/visual_studio_validator.dart:33:24)
<asynchronous suspension>
#2 asyncGuard.<anonymous closure> (package:flutter_tools/src/base/async_guard.dart:111:32)
<asynchronous suspension>
#3 _rootRun (dart:async/zone.dart:1124:13)
#4 _CustomZone.run (dart:async/zone.dart:1021:19)
#5 _runZoned (dart:async/zone.dart:1516:10)
#6 runZoned (dart:async/zone.dart:1500:12)
#7 asyncGuard (package:flutter_tools/src/base/async_guard.dart:109:3)
#8 Doctor.startValidatorTasks (package:flutter_tools/src/doctor.dart:151:11)
#9 Doctor.diagnose (package:flutter_tools/src/doctor.dart:244:41)
#10 _AsyncAwaitCompleter.start (dart:async-patch/async_patch.dart:43:6)
#11 Doctor.diagnose (package:flutter_tools/src/doctor.dart:234:24)
#12 DoctorCommand.runCommand (package:flutter_tools/src/commands/doctor.dart:59:39)
#13 _AsyncAwaitCompleter.start (dart:async-patch/async_patch.dart:43:6)
#14 DoctorCommand.runCommand (package:flutter_tools/src/commands/doctor.dart:45:42)
#15 FlutterCommand.verifyThenRunCommand (package:flutter_tools/src/runner/flutter_command.dart:490:18)
#16 _asyncThenWrapperHelper.<anonymous closure> (dart:async-patch/async_patch.dart:71:64)
#17 _rootRunUnary (dart:async/zone.dart:1132:38)
#18 _CustomZone.runUnary (dart:async/zone.dart:1029:19)
#19 _FutureListener.handleValue (dart:async/future_impl.dart:137:18)
#20 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:678:45)
#21 Future._propagateToListeners (dart:async/future_impl.dart:707:32)
#22 Future._completeWithValue (dart:async/future_impl.dart:522:5)
#23 Future._asyncComplete.<anonymous closure> (dart:async/future_impl.dart:552:7)
#24 _rootRun (dart:async/zone.dart:1124:13)
#25 _CustomZone.run (dart:async/zone.dart:1021:19)
#26 _CustomZone.runGuarded (dart:async/zone.dart:923:7)
#27 _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:963:23)
#28 _microtaskLoop (dart:async/schedule_microtask.dart:41:21)
#29 _startMicrotaskLoop (dart:async/schedule_microtask.dart:50:5)
#30 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:116:13)
#31 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:173:5)
[!] Android Studio (not installed)
• Android Studio not found; download from https://developer.android.com/studio/index.html
(or visit https://flutter.dev/setup/#android-setup for detailed instructions).
[√] Connected device (1 available)
• Windows • Windows • windows-x64 • Microsoft Windows [Version 6.1.7601]
! Doctor found issues in 3 categories.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
a: desktopRunning on desktopRunning on desktopc: crashStack traces logged to the consoleStack traces logged to the consoleplatform-windowsBuilding on or for Windows specificallyBuilding on or for Windows specificallyt: flutter doctorProblem related to the "flutter doctor" toolProblem related to the "flutter doctor" tooltoolAffects the "flutter" command-line tool. See also t: labels.Affects the "flutter" command-line tool. See also t: labels.
Activity
squeezeboxhuf commentedon Sep 11, 2019
Same thing happening for me today - trying to set up Flutter Desktop, I just installed Visual Studio 2019 Community Edition, but flutter doctor not happy with exact same messages as above
daimonkor commentedon Sep 11, 2019
I found the same problem at Windows 10 http://prntscr.com/p4rxi4
stuartmorgan-g commentedon Sep 11, 2019
@franciscojma86 It looks like your mock data doesn't correspond to the actual JSON output from vswhere; you're using a bool for
productMilestoneIsPreRelease, but, e.g., https://devblogs.microsoft.com/setup/new-vswhere-with-more-properties/ shows it as a string. (There's a top-levelisPrereleasethat is a bool; maybe we should be using that?)stuartmorgan-g commentedon Sep 11, 2019
@franciscojma86 Also, I'm noticing that that output doesn't contain
isRebootRequired,isComplete, orisLaunchable, which suggests they were added relatively recently. Given that, you should remove the assertions that they are present, and instead make the code default to returning the "good" answers for each of those keys if they are missing.franciscojma86 commentedon Sep 11, 2019
Fixing!
daimonkor commentedon Sep 11, 2019
@franciscojma86 Please write requirement visual studio (2017 or 2019) components for desktop support. I mean C++ development and etc. Thanks for help.
stuartmorgan-g commentedon Sep 11, 2019
flutter doctoralready provides that information (once the crash is fixed). If you check hashf7d86a5b7950402f5f3e0ff1e2d51e0846b638cbfor instance, which is just before the regression, you'll see that.daimonkor commentedon Sep 11, 2019
@stuartmorgan thanks, found http://prntscr.com/p4vcdi, but what components are needed?
stuartmorgan-g commentedon Sep 11, 2019
@daimonkor Ah, I see what you mean. Thanks for highlighting that flow issue; I filed #40267 to improve the way that's handled. (For now, the answer to your question is 'Desktop development with C++' workload with these components)
daimonkor commentedon Sep 11, 2019
@stuartmorgan thanks for help
stuartmorgan-g commentedon Sep 12, 2019
Yes, the cause of the regression (including the timing of when the change landed) is well understood.
The PR linked above is the fix, it just hasn't landed yet. You can apply it locally if you absolutely need the latest master before it lands.
mofada commentedon Sep 12, 2019
Ok, it has been fixed, please update the
flutter upgradecommand.Fix crash on vswhere search from flutter doctor (#40263)
stuartmorgan-g commentedon Sep 12, 2019
I'm not sure what this means; if you have an issue with
flutter upgrade, please file a new bug with details.If your issue was that you still had this crash after running
flutter upgrade, that is expected behavior, because the fix hadn't landed when you wrote that comment.mofada commentedon Sep 12, 2019
I mean, please update the flutter with
flutter upgradeFix crash on vswhere search from flutter doctor (flutter#40263)
github-actions commentedon Aug 28, 2021
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 -vand a minimal reproduction of the issue.