Skip to content

Set MSRV to 1.76#871

Merged
Urhengulas merged 4 commits intomainfrom
msrv
Oct 11, 2024
Merged

Set MSRV to 1.76#871
Urhengulas merged 4 commits intomainfrom
msrv

Conversation

@Urhengulas
Copy link
Copy Markdown
Member

@Urhengulas Urhengulas commented Oct 9, 2024

This PR documents and tests Rust 1.76 as our MSRV. This is the version Ferrocene 24.05 is based on. Before we only guaranteed to support the latest stable.

I tried to store the MSRV in an env variable in the workflow file, but unfortunately env variables are not available in the strategy matrix, so it has to be repeated.

@Urhengulas Urhengulas added the breaking change fix / feature / improvement involves a breaking change and needs to wait until next minor version label Oct 9, 2024
@Urhengulas Urhengulas force-pushed the msrv branch 3 times, most recently from 062f2af to b84ac7e Compare October 9, 2024 13:03
@Urhengulas Urhengulas force-pushed the msrv branch 3 times, most recently from 39f299f to b64bd19 Compare October 9, 2024 15:01
@Urhengulas Urhengulas marked this pull request as ready for review October 9, 2024 15:07
Comment thread README.md Outdated
Comment thread firmware/defmt-semihosting/src/lib.rs
Comment thread xtask/src/utils.rs
Comment thread xtask/src/main.rs
Comment thread xtask/src/snapshot.rs
"panic_info",
];
const NIGHTLY_SNAPSHOT_TESTS: &[&str] = &["alloc"];
const POST_MSRV_SNAPSHOT_TESTS: &[&str] = &["net"];
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.

It's unclear to me what "post msrv snapshot tests" are. If we raise the msrv should this change?

Copy link
Copy Markdown
Member Author

@Urhengulas Urhengulas Oct 11, 2024

Choose a reason for hiding this comment

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

Yes. We have three brackets of tests

  1. tests that work on the msrv, stable and nightly
  2. tests that work on stable and nightly
  3. tests that work on nightly only

Regarding 2: The default defmt features support the msrv, but some of the optional features require a newer version, e.g. ip_in_core. These tests are the ones in POST_MSRV_TESTS. Maybe OPTIONAL_FEATURE_TESTS is better?

Regarding 3: These tests use unstable features.

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.

So POST_MSRV means "any version above our MSRV"? If so, a little comment would be really nice:

// Tests which run on all Rustc versions later than our MSRV
const POST_MSRV_SNAPSHOT_TESTS: &[&str] = &["net"];

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Well it's not all versions. It's some version in MSRV..=STABLE.

Copy link
Copy Markdown
Member

@Hoverbear Hoverbear left a comment

Choose a reason for hiding this comment

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

No blockers. :)

@Urhengulas Urhengulas added this pull request to the merge queue Oct 11, 2024
Merged via the queue into main with commit 5733f80 Oct 11, 2024
@Urhengulas Urhengulas deleted the msrv branch October 11, 2024 14:27
@Urhengulas Urhengulas mentioned this pull request Oct 11, 2024
@Urhengulas Urhengulas mentioned this pull request Nov 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking change fix / feature / improvement involves a breaking change and needs to wait until next minor version

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants