While running cargo-semver-checks, there was an issue that was surfaced
regarding serde(into), serde(try_from) and schemars(transparent) being
used, and they are incompatible.
This appeared to be a semver issue, on the side of schemars, since the issue
would only appear when adding radicle as a fresh dependency. The intuition for
this is that once schemars was updated locally, the same error appeared when
attempting to build the radicle crate.
To avoid this, schemars provides a ! operator for the macro1:
You can also “unset” serde attributes by including them with a ! prefix in a schemars attribute, which will make schemars ignore the corresponding serde attribute item
https://docs.rs/schemars_derive/latest/schemars_derive/derive.JsonSchema.html#attributes
While running cargo-semver-checks, there was an issue that was surfaced
regarding serde(into), serde(try_from) and schemars(transparent) being
used, and they are incompatible.
This appeared to be a semver issue, on the side of schemars, since the issue
would only appear when adding radicle as a fresh dependency. The intuition for
this is that once schemars was updated locally, the same error appeared when
attempting to build the radicle crate.
To avoid this, schemars provides a ! operator for the macro1:
You can also “unset” serde attributes by including them with a ! prefix in a schemars attribute, which will make schemars ignore the corresponding serde attribute item
https://docs.rs/schemars_derive/latest/schemars_derive/derive.JsonSchema.html#attributes