Skip to content
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

Report newly held back dependencies on all commands #13539

Closed
Tracked by #9930
epage opened this issue Mar 5, 2024 · 2 comments · Fixed by #13561
Closed
Tracked by #9930

Report newly held back dependencies on all commands #13539

epage opened this issue Mar 5, 2024 · 2 comments · Fixed by #13561
Labels
A-dependency-resolution Area: dependency resolution and the resolver C-enhancement Category: enhancement

Comments

@epage
Copy link
Contributor

epage commented Mar 5, 2024

Split out of #9930 for RFC #3537 for a more focused conversation

We need to make sure users know when Cargo selects old dependencies so users can make a conscious choice on their risks. This affects both MSRV and semver

@epage epage added C-enhancement Category: enhancement A-dependency-resolution Area: dependency resolution and the resolver labels Mar 5, 2024
@epage
Copy link
Contributor Author

epage commented Mar 5, 2024

For performance, we can leverage the "is this changed" check that is part of write_pkg_lockfile.

This gets me thinking, should we report all dependency changes on all commands?

  • If you don't have a lockfile already, we likely don't want to report everything as that would be noisy
    • We could put this behind --verbose
  • We'd need to modify the language of the messages so they are understandable in other contexts, like changing "Adding foo v1.0.0" to "Adding dependency foo v1.0.0"
  • I wonder if we should also put "Remove" messages behind verbose

Example:

1   1         Updating `dummy-registry` index
    2    +      Adding dependency baz v0.0.1
2   3      Downloading crates ...
3   4       Downloaded baz v0.0.1 (registry `dummy-registry`)
4   5         Checking baz v0.0.1
5   6         Checking foo v0.0.1 [..]
6   7         Finished [..]

@epage
Copy link
Contributor Author

epage commented Mar 5, 2024

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-dependency-resolution Area: dependency resolution and the resolver C-enhancement Category: enhancement
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant