Skip to content

Conversation

@jonahwilliams
Copy link
Contributor

@jonahwilliams jonahwilliams commented Oct 30, 2020

Description

Fixes auto-detection of sound mode in web projects

@flutter-dashboard flutter-dashboard bot added a: accessibility Accessibility, e.g. VoiceOver or TalkBack. (aka a11y) engine flutter/engine related. See also e: labels. c: contributor-productivity Team-specific productivity, code health, technical debt. tool Affects the "flutter" command-line tool. See also t: labels. labels Oct 30, 2020
@google-cla google-cla bot added the cla: yes label Oct 30, 2020
Copy link
Member

@zanderso zanderso left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm w/o the roll

@jonahwilliams jonahwilliams changed the title [null-safety] roll to null safe dart [null-safety] update tests and tool auto-detection for null safe dart Oct 30, 2020
final LanguageVersion languageVersion = target != null
? packageConfig?.packageOf(Uri.parse(target))?.languageVersion
: null;
final bool isNullSafe = languageVersion != null && languageVersion.major >= 2 && languageVersion.minor >= 11;
Copy link
Contributor

@jakemac53 jakemac53 Oct 30, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A null language version is supposed to mean opt in, fwiw (it means current language version)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TIL!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks - updated to be null safe if the language version is null or is gte 2.11

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How are we going to handle the 2.12 flip here? That will be the sdk where its actually turned on

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll file an issue to adjust the constraints. This is only an approximation of the autodetect logic, so its going to have some holes.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

],
);

// The flutter-tester device cannot be run concurrently in the same project directory.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm disabling these tests because they are timing out but only on CI

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

a: accessibility Accessibility, e.g. VoiceOver or TalkBack. (aka a11y) c: contributor-productivity Team-specific productivity, code health, technical debt. engine flutter/engine related. See also e: labels. tool Affects the "flutter" command-line tool. See also t: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants