[all] Update Dart SDK max to 4.0.0#3509
Conversation
|
|
||
| environment: | ||
| sdk: '>=2.17.0 <3.0.0' | ||
| sdk: ">=2.17.0 <4.0.0" |
There was a problem hiding this comment.
The changes to all of the packages were auto-generated (by a slightly-locally-modified version of update-min-sdk) which is why the quoting changed in packages that were using ' instead of ".
| min: _dartMinVersion, | ||
| includeMin: true, | ||
| max: _dartMinVersion.nextMajor) | ||
| VersionRange(min: _dartMinVersion, includeMin: true, max: upperBound) |
There was a problem hiding this comment.
The changes in this file are the only non-automated changes in the PR.
| // pub special-cases 3.0.0 as an upper bound to be treated as 4.0.0, and | ||
| // using 3.0.0 is now an error at upload time, so special case it here. |
There was a problem hiding this comment.
I had heard about this special casing, I think it only kicks in if your lower bound is modern enough (but I guess packages in this repo have been kept up to date so the 3 -> 4 applies everywhere.)
There was a problem hiding this comment.
Modern enough is 2.12 (NNBD), so we're definitely way past that.
Piinks
left a comment
There was a problem hiding this comment.
LGTM - to infinity & beyond!
|
Merging on red to fix the tree. |

Updates all packages to use <4.0.0 instead of <3.0.0 for Dart SDK constraints.
Also updates the
update-min-sdktooling command to special-case this 3.0.0->4.0.0 transformation when determining the upper bound to use for a given lower bound, so that the command won't undo this change when run.This fixes out-of-band breakage in
publishabledue to a new pub.dev error when using '<3.0.0'.This does not update any versions or changelogs because it's a no-op for clients due to the special casing in the
pubresolver. It's just necessary for future publishing.Pre-launch Checklist
dart format.)[shared_preferences]pubspec.yamlwith an appropriate new version according to the pub versioning philosophy, or this PR is exempt from version changes.CHANGELOG.mdto add a description of the change, following repository CHANGELOG style.///).