dart-lang / linter

Linter for Dart.
https://dart.dev/tools/linter-rules
BSD 3-Clause "New" or "Revised" License
628 stars 170 forks source link

Removing low-priority lint rules #5073

Open srawlins opened 1 month ago

srawlins commented 1 month ago

If we land analyzer plugins well, we may choose to stop supporting our lowest-priority lint rules. Maybe lint rules that do not guard against errors or bloat, and are not in the lints:core or lints:recommended sets, and are not used by the Dart or Flutter teams or Google, and are not backed by Effective Dart.

If any team or user found any such removed rule useful, they could resurrect it themselves quite easily, as the new plugins API uses the existing API for defining a first-party lint rule.

I thought I'd jot down some ideas to see what the scope of this might be. I personally think we could remove:

lrhn commented 4 days ago

I'd say these ones do avoid bloat:

Not a lot of bloat, but still unnecessarily long code.

A little sad for eol_at_end_of_file, but that's something your editor should be doing anyway, so not really lint-worthy. A few of the rest will be "good riddance" from me, but most really don't matter any more. If ever. (SGTM!)

eernstg commented 4 days ago

They look like local syntactic style related rules. Probably not something that anyone would miss a lot.

One exception: always_specify_types seems to be the target of a healthy dose of complaints, but is it really true that nobody cares about that one?

pq commented 3 days ago

I love the idea of a clean up! If we do something like this, it'd be nice to get crisp on criteria for removal. Should it matter if the proposed rules are in broad adoption?