Skip to content

fix(lock): Use more accurate 'highest, rather than 'latest' - #17317

Merged
weihanglo merged 2 commits into
rust-lang:masterfrom
epage:min-publish-lock
Aug 5, 2026
Merged

fix(lock): Use more accurate 'highest, rather than 'latest'#17317
weihanglo merged 2 commits into
rust-lang:masterfrom
epage:min-publish-lock

Conversation

@epage

@epage epage commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

What does this PR try to resolve?

Using "latest" is already inaccurate because patches for previous versions can be released. With min-publish-age adding a time dimension, using "latest" becomes a non-starter.

So instead use "highest". We could have used "maximum" but "highest" felt nicer to me for some reason.

This is part of #17009

How to test and review this PR?

@rustbot rustbot added A-cli Area: Command-line interface, option parsing, etc. A-cli-help Area: built-in command-line help A-documenting-cargo-itself Area: Cargo's documentation Command-update S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 5, 2026
@rustbot

rustbot commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

r? @weihanglo

rustbot has assigned @weihanglo.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: @epage, @weihanglo
  • @epage, @weihanglo expanded to epage, weihanglo

@weihanglo weihanglo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense. Some other package managers also use highest. Even our current doc uses highest.

Generally, Cargo prefers the highest version currently available.

https://doc.rust-lang.org/nightly/cargo/reference/resolver.html#version-numbers

View changes since this review

@weihanglo
weihanglo added this pull request to the merge queue Aug 5, 2026
Merged via the queue into rust-lang:master with commit 7759f8c Aug 5, 2026
29 checks passed
@rustbot rustbot removed the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Aug 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-cli Area: Command-line interface, option parsing, etc. A-cli-help Area: built-in command-line help A-documenting-cargo-itself Area: Cargo's documentation Command-update

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants