dart-lang / pana

Package ANAlysis for Dart
https://pub.dev/packages/pana
BSD 3-Clause "New" or "Revised" License
207 stars 44 forks source link

"Support up-to-date dependencies" check doesn't make sense with Flutter package pinning #1271

Closed ethanblake4 closed 1 year ago

ethanblake4 commented 1 year ago

Flutter's package pinning means it can sometimes be impossible to both pass the up-to-date dependencies check and be compatible with Flutter.

For example, my package dart_eval depends on directed_graph, and the latest version of directed_graph (v0.4.0) depends on collection v1.18.0 (its latest stable release).

However, the stable release of flutter_test pins collection to v1.17.2. Therefore, I cannot use the latest version of directed_graph in dart_eval if I want it to be compatible with Flutter projects.

So in exchange for putting in effort to make my package compatible with the stable Flutter SDK, Pana demotes the package by 10 points for not using the latest version of directed_graph. That's pretty nonsensical, imo.

ethanblake4 commented 1 year ago

Nevermind, I realized I can just specify a ranged dependency constraint (although this might not work in cases where packages have breaking changes)