Skip to content

Conversation

kpreid
Copy link
Contributor

@kpreid kpreid commented Aug 5, 2025

Adds a recommendation that, to mitigate “possibly breaking” Rust version requirement increases, they should be declared using package.rust-version.

My main goal in this change is to make it possible to find the Rust version section in this page by searching it, but the most appropriate way to fit it into this section seemed to me to be making this recommendation. Declaring (and maintaining) package.rust-version is additional work, but it is a much lesser burden on maintainers than other items in the same list such as "Provide a large window of support".

Adds a recommendation that, to mitigate “possibly breaking” Rust
version requirement increases, they should be declared using
`package.rust-version`.

My main goal in this change is to make it *possible to find* the Rust
version section in this page by searching it, but the most appropriate
way to fit it into this section seemed to me to be making this
recommendation. Declaring (and maintaining) `package.rust-version` is
additional work, but it is a much lesser burden on maintainers than
other items in the same list such as "Provide a large window of support".
@rustbot
Copy link
Collaborator

rustbot commented Aug 5, 2025

r? @ehuss

rustbot has assigned @ehuss.
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

@rustbot rustbot added A-documenting-cargo-itself Area: Cargo's documentation S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 5, 2025
Copy link
Member

@weihanglo weihanglo left a comment

Choose a reason for hiding this comment

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

Thanks for the contribution!

@kpreid kpreid requested a review from epage September 28, 2025 15:30
@epage
Copy link
Contributor

epage commented Sep 29, 2025

Mind cleaning up the commits into logical, atomic units rather than the history of how this was implemented?

to update their Rust toolchain rapidly.

Mitigation strategies:
* Specify your package’s minimum-supported Rust version by setting
Copy link
Contributor

Choose a reason for hiding this comment

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

If making changes to the history, one last tweak (I know, I recommended this wording):

Suggested change
* Specify your package’s minimum-supported Rust version by setting
* Document your package’s minimum-supported Rust version by setting

This changes the base assumption to be that this item is for if you have an MSRV and so you likely also verify it. We have the note at the end about support considerations but people are likely to miss that when scanning through this.

I'm tempted to tweak this further to find a way to make it clear that an MSRV isn't always literally what compiles but not finding a great way, so leaving it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-documenting-cargo-itself Area: Cargo's documentation S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants