question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Flutter SDK and/or Dart SDK settings keep changing while Android Studio is running

See original GitHub issue

Thanks for the feedback! If your issue is related to the Flutter framework itself, please open an issue at github.com/flutter/flutter.

Steps to Reproduce

  1. Running Android Studio on Mac
  2. Change Dart SDK from flutter installed version to Homebrew installed 2.2.0. Click Apply and then OK.
  3. After some time, maybe restart the IDE, notice that the skip parameter for a test method is not recognized as defined.
  4. I will go to the settings and see that either the Dart SDK reverts back to the version used by flutter and/or the Flutter SDK is set as empty or undefined.

Manually changing the Dart SDK back to the version used by flutter may not correct the issue seen in the IDE. Going back to the setting, the Flutter SDK may have been changed by the IDE/plugin or the Dart SDK is re-set to the non-flutter installed version.

It’s very hard to understand the logic. For the Dart SDK, I may even set it to look for updates on the Stable channel only and even that would get undone when the Dart SDK gets auto changed.

Look at the following screenshots (look at the time stamps to see how quickly the settings change on their own.

  • at 6:11:57 PM Screen Shot 2019-03-20 at 6:11:57 PM

  • at 6:12:06 PM Screen Shot 2019-03-20 at 6:12:06 PM

  • at 6:12:18 PM I changed the Flutter SDK Screen Shot 2019-03-20 at 6:12:18 PM

  • at 6:12:43 PM, noticed it had no impact and the IDE still reported the same issue (skip not defined) Screen Shot 2019-03-20 at 6:12:43 PM

  • at 6:12:51 PM - Flutter remains unchanged Screen Shot 2019-03-20 at 6:12:51 PM

  • at 6:12:59 PM - The Dart SDK setting changed with no user input Screen Shot 2019-03-20 at 6:12:59 PM

  • at 6:13:27 PM - Flutter is set as empty/undefined with no user input Screen Shot 2019-03-20 at 6:13:27 PM

Version info

flutter doctor --verbose [✓] Flutter (Channel stable, v1.2.1, on Mac OS X 10.14.3 18D109, locale en-US) • Flutter version 1.2.1 at /Users/User/flutter • Framework revision 8661d8aecd (5 weeks ago), 2019-02-14 19:19:53 -0800 • Engine revision 3757390fa4 • Dart version 2.1.2 (build 2.1.2-dev.0.0 0a7dcf17eb)

[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3) • Android SDK at /Users/User/Library/Android/sdk • Android NDK location not configured (optional; useful for native profiling support) • Platform android-28, build-tools 28.0.3 • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1248-b01) • All Android licenses accepted.

[✓] iOS toolchain - develop for iOS devices (Xcode 10.1) • Xcode at /Applications/Xcode.app/Contents/Developer • Xcode 10.1, Build version 10B61 • ios-deploy 1.9.4 • CocoaPods version 1.6.1

[✓] Android Studio (version 3.3) • Android Studio at /Applications/Android Studio.app/Contents • Flutter plugin version 33.4.1 • Dart plugin version 182.5215 • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1248-b01)

[✓] IntelliJ IDEA Ultimate Edition (version 2018.3.5) • IntelliJ at /Applications/IntelliJ IDEA.app • Flutter plugin version 30.0.2 • Dart plugin version 183.5912.23

[!] Connected device ! No devices available

! Doctor found issues in 1 category. Process finished with exit code 0

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:8 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
stevemessickcommented, Feb 12, 2021

Possibly. I’m not familiar with VS Code, but getting a new SDK was the key point of my previous remark.

1reaction
stevemessickcommented, Mar 21, 2019

The Flutter SDK contains a Dart SDK that it is designed to work with. Manually setting the Dart SDK is not supported when the Flutter plugin is installed.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why I can't change Dart-SDK path and version in Android ...
The current Dart SDK version is 2.14.4. I close the Android Studio app, then I open it again. I run "flutter pub get"...
Read more >
Dart SDK not configured in Android Studio How to Fix Flutter ...
How to install Flutter SDK on MacOS: https://youtu.be/1mZO0toBXFc.
Read more >
How To Fix Dart SDK Is Not Configured In Android ... - YouTube
Could not find a Flutter SDK. Please ensure flutter is installed and in your PATH. master_error! master_error!
Read more >
Dart SDK is not configured Android Studio [ Fixed 2021 ]
In this tutorial, you will fix the issue Dart SDK is not configured in Android Studio. Therefore, you have to watch the tutorial...
Read more >
How to Solve Dart SDK is not Configured in Flutter??
Click Android Studio on top -> Click on Preferences -> Languages & Framework-> Select Flutter -> Browse Flutter SDK Path you have download...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found