Radish alpha
h
rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5
Radicle Heartwood Protocol & Stack
Radicle
Git
radicle: fix build when schemars feature is not enabled
Merged did:key:z6Mkm3WR...9jjY opened 11 months ago

Commit b608a788 (cli: rad config schema emits JSON Schema, 2025-04-28) added a feature flag that enables the “schemars” optional dependency.

Crate radicle-node doesn’t use this feature. Crate radicle fails to compile when the feature is disabled. This is reproducible with “flake check”. Fix it.

Note that a “cargo build” of the entire workspace doesn’t fail, because the feature is enabled due to “unification”, since “radicle-cli” does use this feature. From https://doc.rust-lang.org/cargo/reference/resolver.html#features:

When building multiple packages in a workspace (such as with –workspace or multiple -p flags), the features [of the dependencies] of all of those packages are unified. If you have a circumstance where you want to avoid that unification for different workspace members, you will need to build them via separate cargo invocations.

did:key:z6Mkm3WR...9jjY opened with revision aa024a6a on base 1a67ac18 +4 -4 11 months ago

Commit b608a788 (cli: rad config schema emits JSON Schema, 2025-04-28) added a feature flag that enables the “schemars” optional dependency.

Crate radicle-node doesn’t use this feature. Crate radicle fails to compile when the feature is disabled. This is reproducible with “flake check”. Fix it.

Note that a “cargo build” of the entire workspace doesn’t fail, because the feature is enabled due to “unification”, since “radicle-cli” does use this feature. From https://doc.rust-lang.org/cargo/reference/resolver.html#features:

When building multiple packages in a workspace (such as with –workspace or multiple -p flags), the features [of the dependencies] of all of those packages are unified. If you have a circumstance where you want to avoid that unification for different workspace members, you will need to build them via separate cargo invocations.

lorenz accepted 11 months ago

Thanks for cleaning up my mess 🙌

lorenz merged revision aa024a6a at 059c8045 11 months ago