Conversation
It will display a warning with old Cargo versions, however it's also displayed on crates.io.
This fixes some scary undefined behavior. 😬
Cargo.toml
Outdated
|
|
||
| [workspace] | ||
| members = [ | ||
| "benches", |
There was a problem hiding this comment.
I think it's better to exclude benches from the root workspace and test its build in a separate CI job.
There was a problem hiding this comment.
But it is part of the workspace.
There was a problem hiding this comment.
It's our decision whether to include a crate into workspace or not. In rand we exclude benches because criterion is a relatively heavy dependency and it's somewhat wasteful to build it during crate tests.
There was a problem hiding this comment.
Oh, you managed to sneak that change into rust-random/rand#1448
There was a problem hiding this comment.
And your CI script tests the base repo, not the benches package. Check the log:
https://github.com/rust-random/rand/actions/runs/9008465527/job/24750605137
There was a problem hiding this comment.
The Clippy complaining was probably because working dir was not changed in the previous version of the config.
I fixed that; it alone wasn't enough. And try e.g. cargo test -p rand_hc from the benches dir; it should not work but it does!
There was a problem hiding this comment.
Maybe we also need to add package.workspace = "." to benches' Cargo.toml?
There was a problem hiding this comment.
Result:
$ cargo test
error: root of a workspace inferred but wasn't a root: /home/dhardy/projects/rand/rngs/benches/Cargo.toml
There was a problem hiding this comment.
I think it's just a Cargo bug we have to deal with... lets merge this?
There was a problem hiding this comment.
Ah, yes. I meant:
[workspace]
members = ["."]UPD: Hm, nope. cargo test -p rand_core still works from the benches folder.
e51461b to
de7898e
Compare
| rust-version = "1.61" | ||
| publish = false | ||
|
|
||
| [dependencies] |
There was a problem hiding this comment.
The empty dependencies section can be removed.
This replaces #50.
All crates are now using MSRV = 1.61, the same as rand. If we're going to maintain these crates, we should at least do so using the same Rust version we use elsewhere.
To do later (in new PRs):
randversion frommasteruntil next release; moverand_pcghere.