Correct the stale flutter_lints constraint comment - #5
Merged
Conversation
Dependabot widened the constraint to ">=5.0.0 <7.0.0" (4f89c3d), but the comment above it still claimed "we pin to 5.x". Anyone reading it would conclude the constraint had drifted from its intent and re-pin it. The range is actually the right answer, so document why rather than reverting: Dart 3.6 contributors resolve 5.x and can still run `pub get`, newer SDKs resolve 6.x, and CI covers both — the pinned 3.27 job exercises 5.x, the stable matrix exercises 6.x. Verified with a fresh resolve to flutter_lints 6.0.0 / lints 6.1.0: analyze reports no issues and all 40 tests pass. Also warn against narrowing to ^6.0.0, which breaks `pub get` on the declared minimum and had to be reverted once already in 5ddbd67. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Dependabot widened
flutter_lintsto">=5.0.0 <7.0.0"in 4f89c3d, but the comment directly above it still said "we pin to 5.x". The constraint and its documentation now disagree, and a contributor reading that comment would reasonably conclude the pin had drifted and re-pin it — undoing a change that is actually correct.Type of change
Comment-only. No constraint, code, or version change.
Why keep the range instead of re-pinning
The range satisfies the original intent better than the pin did:
pub get.Flutter 3.27.0job covers 5.x, the stable matrix covers 6.x.pubspec.lockis gitignored, so every CI job resolves fresh.Verified locally with a fresh resolve to
flutter_lints 6.0.0/lints 6.1.0:flutter analyzereports no issues and all 40 tests pass.The new comment also warns against narrowing to
^6.0.0, which breakspub geton the declared minimum — that exact bump had to be reverted once already in 5ddbd67.Checklist
flutter analyzereports zero errorsflutter testpasses locallyCHANGELOG.mdhas an entry describing the change — n/a, comment onlydart format .was run on modified files🤖 Generated with Claude Code