rapier
rapier copied to clipboard
Build breakage with 0.18 in `SolverConstraintsSet`
Building with Rust-1.73:
error[E0446]: crate-private type `SolverConstraintsSet<contact_constraints_set::ContactConstraintTypes>` in public interface
--> /home/kvark/.cargo/registry/src/index.crates.io-6f17d22bba15001f/rapier3d-0.18.0/src/dynamics/solver/contact_constraint/contact_constraints_set.rs:87:1
|
87 | pub type ContactConstraintsSet = SolverConstraintsSet<ContactConstraintTypes>;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ can't leak crate-private type
|
::: /home/kvark/.cargo/registry/src/index.crates.io-6f17d22bba15001f/rapier3d-0.18.0/src/dynamics/solver/solver_constraints_set.rs:39:1
|
39 | pub(crate) struct SolverConstraintsSet<Constraints: ConstraintTypes> {
| -------------------------------------------------------------------- `SolverConstraintsSet<contact_constraints_set::ContactConstraintTypes>` declared as crate-private
My Cargo lock entry:
[[package]]
name = "rapier3d"
version = "0.18.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "92d07a833e0aa3bc57010caaa50bf75fa78afc03a74207607db740da4e4579a1"
...
I see similar errors (e.g. https://github.com/dimforge/rapier/issues/586) are reported recently not only in this repo.
I found this error was relaxed only since Rust 1.74.0. This change:
Replace private_in_public lint with private_interfaces and private_bounds per RFC 2145. Read more in RFC 2145.
Since rapier doesn't have a policy about MSRV (right?), technically, this might not be what is considered as a semver breakage. But, I personally feel Rust 1.74 is a bit too strict requirement for a non-experimental library.
@kvark I’m not sure I understand what semver breakage means here. Rapier got bumped from 0.17 to 0.18 here, isn’t hat what semvers dictates in case of breaking change (apparently including, in this case, a MSRV change)?
Sorry about the confusion! I was reporting other similar issues to other repos, and they were actually semver-related. For Rapier3d, it's not about semver at all. Let me edit the title accordingly.
I strongly recommend exposing MSRV and having your CI build/run with it specifically instead of the latest stable version.