-
Notifications
You must be signed in to change notification settings - Fork 319
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Notify user when the Dart SDK differs from the one bundled with Flutter #54
Comments
See also flutter/flutter#3449 |
It will definitely be confusing :) Please override whatever Dart SDK is configured by the user over in the dart plugin, and use whatever Dart SDK is vendored by Flutter when editing a Flutter app. Also, consider allowing each project to have a Flutter SDK setting. A global setting, for all projects across the IDE, makes it hard to have project A using Flutter 1.2.3 and project B using Flutter 2.1.1. |
Right. This brings up the larger issue which is that the Dart Plugin currently does not support per-project SDKs.... cc @jwren for some background. |
To be clear, Flutter isn't released in a way that makes this super easy. But, we'll get there before we know it. And as long as we're talking about configurations, I'd like us to think about how to do per-project SDK configurations. |
This is a large issue, see flutter/flutter#3770 for more context. Our current focus is internal where this doesn't occur, but as Seth notes, external deployments are going to sneak up on us soon. So we definitely need to design for a world where folks can have multiple flutter projects not all of which use the same versions of flutter (and thus Dart). Not sure what the entire solution looks like, but please do plan for such a world. :) |
Added a separate tracking bug for the per-project SDKs ask (#56). Thanks for all the input! :) |
An editor notification (in progress), that nags if the SDKs are not the same. @sethladd : wordsmithing appreciated! |
Great progress Phil! |
Sorry, I'm confused. Why does this check exist? Shouldn't a Flutter project's Dart SDK be auto-set from the Flutter SDK that they've pointed to. In other words, shouldn't the Flutter project's settings be decoupled from a Dart project's settings? Why are we (apparently?) forcing our users to have a single Dart SDK configured for all projects in IntelliJ that might be using Dart? (apologies if I'm not understanding what this message is telling our users...) |
Absolutely. That's what we're shooting for but the Dart plugin does not support per-module SDKs. I opened #56 to track this at the Flutter plugin level but this is really a deeper issue with Dart support in general. @jwren feel free to chime in... Otherwise, perhaps we should all VC to discuss? |
I think we're as far as we want to go on this for a first cut. Flutter SDK configuration should set the right SDK and if a user has done something different they'll see an editor notification. Feel free to re-open if you want to continue to iterate. Or maybe better still, open new issues to track specific asks. |
It may be confusing to users if the default SDK defined in the Dart Plugin and the one bundled with Flutter disagree. An easy mitigation would be to define an inspection that detects this case and notifies the user. They may choose to correct it or ignore it.
Two places where this might make sense:
In both places the warning should be dismissible.
cc @devoncarew
The text was updated successfully, but these errors were encountered: