3 ms·
The SemVer in Rust/Cargo is pretty good with some caveats: - Minimum Supported Rust Version doesn't play into it, and that's been a topic of debate. - Build t
by swsieber 6y ago
The SemVer in Rust/Cargo is pretty good with some caveats:
- Minimum Supported Rust Version doesn't play into it, and that's been a topic of debate.
- Build time dependencies don't play into (I think).
But generally the Rust ecosystem takes code stability fairly seriously and the SemVer oriented bits have done a lot of good.
It does get hairy if you try to explicitly use older versions (e.g. early minor versions of a specific major version) as Cargo tries to pick the most recent release available. I haven't much about this in practice.
- chrismorgan 6y agoBaking SemVer in and having an ecosystem-wide convention to use SemVer (which I hope will in the future be strengthened by machine-checking API compatibility and defaulting to rejecting incompatible changes) gives you sane defaults. You can still specify weird dependencies if you choose to: `foo = ">= 1.2.3, < 1.4.5"`. I definitely wish MSRV was considered in Cargo’s resolution algorithm. This is definitely the biggest issue in Rust package versioning. But if it was, that’d leave the security arguments in play, as now you could be being silently fed an old, insecure version of a package.
- froh 6y agoTIL MSRV minimum supported rust version https://github.com/rust-embedded/wg/blob/master/ops/msrv.md https://github.com/rust-embedded/wg/blob/master/ops/msrv.md