Elevate messages from `dart pub get`
See original GitHub issueWe put a lot of work into messages coming out of dart pub get
.
We have messages like:
- Current package version have been retracted.
- Newer a.b.c version available.
- Package is discontinued.
- Package is discontinued, replaced by package:foo.
- Summaries of changes.
- Content hash from
pubspec.lock
doesn’t match content from server (new in 2.19) - Package version affected by security advisory (coming in the future)
Perhaps we should start a conversation about how we can highlight this information to users.
Context: we sometimes discover that users run into issues that were fixed 2 months ago, because they never run dart pub upgrade
, even after an SDK upgrade.
Maybe, improving messaging here could help. This is just to open a discussion, maybe we’d want pub to have other output. Or maybe this is better injected through the LSP.
cc @sigurdm, @szakarias
Issue Analytics
- State:
- Created 10 months ago
- Comments:8 (6 by maintainers)
Top Results From Across the Web
dart pub get
Get is one of the commands of the pub tool. ... This command gets all the dependencies listed in the pubspec.yaml file in...
Read more >"pub get" consistently fails on Windows · Issue #1798 - GitHub
I am working on a Flutter app on Windows and everything used to work fine. However, today I started to see the following...
Read more >Flutter: pub get failed (66) - Stack Overflow
To fix this go to their respective folders which are in the flutter folder and the first start with the bin folder and...
Read more >flash | Flutter Package - Pub.dev
This library allows you to show messages or alerts in your app quickly and easily. It can be used as an alternative to...
Read more >Flutter Alert Messages, Shaders & Co. - PUB.DEV RELEASES
PUB.DEV RELEASES via EMAIL? Subscribe now at http://follow.syntacops.com/ FULL PLAYLIST at http://releases.syntacops.com/ PREVIOUS ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
In terms of having a place to display richer information, perhaps we could decorate the pubspec.yaml file when the user opens it? We could use synthetic labels after a package dep to display additional information about the package:
Having it on disk has some advantages - both the LSP server (which can produce diagnostics/quick-fixes) and the IDE (which may want to surface some of these things in specific ways that are UI/editor-specific and never likely to fall inside LSP) can access it without spawning (duplicate) commands (plus it removes some complexity of actually running commands, providing output to the user if the command fails/hangs, etc.). If we did this, we should ensure there’s a timestamp in it so tell how fresh the data is (since unlike invoking a command directly, it could easily be stale and I’m not sure we want to rely on the file timestamps).
For some things (like security advisories), I feel like the status bar with some coloured indicator could be good - however it’s less simple to invoke a quick-fix from there because it’s not driven by the analysis server. We could probably handle this with a well-known server command that could be invoked if you chose to ignore it though (which lets the server produce the pubspec edits).
Is it worth trying to come up with an example of some JSON for the the kind of information you have for each of these? Perhaps some of them can be generalised (so the IDE/server don’t need to quite know the specifics of every item if many of them will generally be treated the same, just with some different text/identifier).