Closed droundy closed 4 months ago
It seems to be incorrect that rkyv
is enabled by rust_decimal
if the rust_decimal/std
feature is enabled.
It's only enabled if the rust_decimal/rkyv
feature is also enabled.
Note the presence of the ?
here (documentation).
It gets resolved in the Cargo.lock
for some reason, but cargo check
will not compile it, nor does it appear in cargo tree
.
The fact it appears in Cargo.lock
here but not if the std
feature is not enabled seems to be more a Rust issue: I don't think it should be resolved there...
I'd guess that's probably a hack on their end to enable the feature conditionally on the crate being a dep of something else.
It's also probably an issue at cargo vet
: it probably shouldn't complain about something that doesn't appear in cargo tree
.
The rationale behind enabling this feature was:
serde_avro_fast
requires std
anyway, so let's just not restrict access to all functions or compilation paths that require std to workrust_decimal
has this feature enabled by default I felt like this would reduce the odds of random breakage (if they make a mistake)
This reduces the number of dependencies, and
cargo check
andcargo test
still run fine.It came up because I was setting up
cargo vet
in my code, and was surprised to seerkyv
in our list of dependencies. It'll be nice to have fewer dependencies to audit, andrkyv
would be a particularly hefty crate to audit.Of course, it's also nice for compile times to avoid depending on so many crates.