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

add MSRV #242

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

add MSRV #242

wants to merge 1 commit into from

Conversation

danieleades
Copy link
Contributor

adds an MSRV check to CI

this check ensures that changes to dependencies or syntax in this repo don't inadvertently force downstream users to bump their compiler versions.

the clippy msrv config also prevents clippy from suggesting changes that are not supported by the MSRV toolchain

An MSRV bump should be a patch change before 1.0.0, and a minor change afterwards

@codecov
Copy link

codecov bot commented Dec 1, 2022

Codecov Report

Base: 78.60% // Head: 78.60% // No change to project coverage 👍

Coverage data is based on head (9c344b5) compared to base (8ca80dd).
Patch has no changes to coverable lines.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #242   +/-   ##
=======================================
  Coverage   78.60%   78.60%           
=======================================
  Files          18       18           
  Lines         589      589           
=======================================
  Hits          463      463           
  Misses        126      126           
Impacted Files Coverage Δ
eventually-postgres/tests/aggregate_repository.rs 93.18% <0.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

Copy link
Collaborator

@ar3s3ru ar3s3ru left a comment

Choose a reason for hiding this comment

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

I wouldn't mind adding MSRV once again, but only if there is a pain-free way to "infer" it.
Is there any official documentation on how to do it?

I tried some time ago, the only tool I found was https://github.com/foresterre/cargo-msrv, which is gloriously failing on my dev machine since it uses rustup and I can't use that (NixOS machine).

If it's something I can't maintain, I'd rather not specify it honestly and just target latest stable always.
I know that's not the nicest stance to take, but better than a broken experience 🤷🏻‍♂️

@danieleades
Copy link
Contributor Author

I wouldn't mind adding MSRV once again, but only if there is a pain-free way to "infer" it. Is there any official documentation on how to do it?

I tried some time ago, the only tool I found was https://github.com/foresterre/cargo-msrv, which is gloriously failing on my dev machine since it uses rustup and I can't use that (NixOS machine).

I use cargo-msrv, which is pretty straightforward on my machine. Have you tried raising a ticket against the project for NixOS support?

It looks like some work has been done here already, so it may Just Work for you

If it's something I can't maintain, I'd rather not specify it honestly and just target latest stable always. I know that's not the nicest stance to take, but better than a broken experience 🤷🏻‍♂️

depends what you mean by 'stable'. For example using variables directly inside format strings was just stabilised, so you can now do

format!("key: {value}");

instead of

format!("key: {}", value);

But if you were to switch to that syntax the moment it was available, you'd break the build for any downstream users that weren't using the very latest stable compiler. Adding an MSRV target gives you a way to tell if you've potentially just broken other people's builds with a PR.

@ar3s3ru
Copy link
Collaborator

ar3s3ru commented Dec 10, 2022

Hey @danieleades 👋🏻

Going back to this PR.
How would you feel about adding an Action step to calculate the latest MSRV on the Github Actions runner? 👀

Might be easier in terms of maintenance, and I would be more than willing to add an MSRV version then 👌🏻

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants