Skip to content

Correct the stale flutter_lints constraint comment - #5

Merged
sovanken merged 1 commit into
mainfrom
chore/lints-constraint-comment
Aug 14, 2026
Merged

Correct the stale flutter_lints constraint comment#5
sovanken merged 1 commit into
mainfrom
chore/lints-constraint-comment

Conversation

@sovanken

Copy link
Copy Markdown
Owner

Summary

Dependabot widened flutter_lints to ">=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

  • Documentation only (README, dartdoc, CHANGELOG)

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:

  • Dart 3.6 contributors (our declared minimum, Flutter 3.27) resolve 5.x and can still run pub get.
  • Newer SDKs resolve 6.x.
  • CI exercises both — the pinned Flutter 3.27.0 job covers 5.x, the stable matrix covers 6.x. pubspec.lock is gitignored, so every CI job resolves fresh.

Verified locally with a fresh resolve to flutter_lints 6.0.0 / lints 6.1.0: flutter analyze reports no issues and all 40 tests pass.

The new comment also warns against narrowing to ^6.0.0, which breaks pub get on the declared minimum — that exact bump had to be reverted once already in 5ddbd67.

Checklist

  • flutter analyze reports zero errors
  • flutter test passes locally
  • Public API changes are documented via dartdoc — n/a
  • CHANGELOG.md has an entry describing the change — n/a, comment only
  • dart format . was run on modified files

🤖 Generated with Claude Code

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>
@sovanken
sovanken merged commit 585e880 into main Aug 14, 2026
4 checks passed
@sovanken
sovanken deleted the chore/lints-constraint-comment branch August 14, 2026 04:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant