-
Notifications
You must be signed in to change notification settings - Fork 159
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
pana not recognizing Flutter package when pubspec.yaml doesn't have Flutter SDK in environment #8486
Comments
Seems like pana choses to resolve the package as a dart-only package. (Not sure why that doesn't happen locally, probably it falls back to the flutter sdk if you don't have a dart-only sdk installed .) Try to augment the
|
@marianz-bonfire: Your
It could be like:
Otherwise the analysis ( |
We could update pana on pub.dev to attempt resolving with the dart sdk first - and then with the flutter sdk,... somehow. (I'd still recommend adding a flutter constraint though) |
@isoos @sigurdm Interestingly, I didn’t expect this to be an issue because, based on my previous packages published on pub.dev, there were no problems even though their pubspec.yaml files followed a similar structure. Those packages achieved full analysis scores without the explicit Flutter SDK constraint. I'll update the pubspec.yaml file to include the Flutter SDK constraint as per your suggestion. And provide feedback immediately after testing it and let you know the results. Thank you again for your assistance and insights! 👏 |
The exact method of detection is a bit more than that constrain:
Maybe your other package depended on one of the first two? |
Im encountering an issue when publishing a tarsier_local_storage package to pub.dev. The analysis fails, even though all tests run successfully when executed locally.
On my first publish, the package succeeded with 50/160 pub points. After making some fixes, I tried to publish a new version, but that's when the analysis started failing.
I am currently working on figuring out a solution. However, I wanted to raise this issue in the meantime in case you can provide immediate assistance.
I've reviewed previous issues, and while this might be a redundancy, I wanted to ensure it was highlighted in case it provides new insights or hasn't been fully addressed yet.
Commands executed locally
flutter --version
dart --version
dart analyze
dart doc .
pana
Analysis Results of pub dev
pub.dev analysis log
Score screenshot
As you can see, running the
pana
test locally, I received 150/160 pub points. However, on pub.dev, the package fails the analysis. This discrepancy is very puzzling since some of my previously published packages achieved 160/160 pub points on pub.dev, even though they were rated 150/160 locally withpana
.The text was updated successfully, but these errors were encountered: