fix(release): repair make publish crate set, order and dev-dep cycles - #256
Merged
Merged
Conversation
`make publish` could not complete. It failed at `cargo publish -p aimdb-tokio-adapter`, and no reordering of the list could fix it: three workspace library crates were absent from the list entirely, and the dependency graph was cyclic once dev-dependencies were counted. Three changes, no code movement. Add the three missing connectors. `aimdb-uds-connector`, `aimdb-serial-connector` and `aimdb-tcp-connector` are published API — `aimdb-client` already exposes all three behind its `transport-*` features, and `cargo publish` requires every dependency to resolve on the registry, optional ones included. Replace the hand-numbered 16-step list with a `PUBLISH_ORDER` variable driving a loop, so the order has one source of truth and the step numbering derives from it. The order is topological over normal and build dependencies, verified against `cargo metadata`. `PUBLISH_NO_VERIFY` carries the two crates that skip verification, keeping the existing behaviour explicit rather than buried in one line of the sequence. Drop `version =` from the workspace-internal dev-dependencies, keeping `path`. Cargo omits path-only dev-dependencies when packaging, so the cycle disappears at publish time while `cargo test` still resolves locally. Five needed it, not the three first identified: the edge `aimdb-tokio-adapter -> aimdb-client` appears in four of the five elementary cycles, and `aimdb-embassy-adapter -> aimdb-core = "1.1.0"` would have built the packaged tests against the previously published core rather than the code being released. Conversely, `aimdb-websocket-connector -> aimdb-tokio-adapter` forms no cycle — nothing reaches the websocket connector from the tokio adapter — but it carries the same stale-version hazard and is fixed on that basis. Also mark `remote-access-demo` as `publish = false`. It was the only example crate missing the flag, which left it as a 20th publishable crate that no publish list mentioned. Verified: the target runs end to end against a stubbed `cargo`, emitting 19 publishes in the listed order with `--no-verify` on exactly the two intended crates, and aborting on the first failure; `cargo metadata` reports no versioned workspace-internal dev-dependencies remain and the list matches the publishable set exactly; the packaged-manifest behaviour was reproduced on a scratch workspace, whose `.crate` carries an empty `[dev-dependencies]` section; and `cargo check --all-targets` passes for every affected crate. `make publish` is still not runnable end to end: `aimdb-embassy-adapter` needs embassy-sync's `poll_next_message` / `poll_changed`, which are merged upstream but absent from the released 0.8.0 and supplied locally through `[patch.crates-io]`. That is recorded on `PUBLISH_NO_VERIFY` and is the remaining blocker. Refs #242 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GgvcFC4S8Kii5H6xzW56mi
4 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
make publishcould not complete. It failed atcargo publish -p aimdb-tokio-adapter, and no reordering of the list could fix it: threeworkspace library crates were absent from the list entirely, and the
dependency graph was cyclic once dev-dependencies were counted.
Three changes, no code movement.
Add the three missing connectors.
aimdb-uds-connector,aimdb-serial-connectorandaimdb-tcp-connectorare published API —aimdb-clientalready exposes all three behind itstransport-*features, and
cargo publishrequires every dependency to resolve on theregistry, optional ones included.
Replace the hand-numbered 16-step list with a
PUBLISH_ORDERvariabledriving a loop, so the order has one source of truth and the step
numbering derives from it. The order is topological over normal and build
dependencies, verified against
cargo metadata.PUBLISH_NO_VERIFYcarries the two crates that skip verification, keeping the existing
behaviour explicit rather than buried in one line of the sequence.
Drop
version =from the workspace-internal dev-dependencies, keepingpath. Cargo omits path-only dev-dependencies when packaging, so thecycle disappears at publish time while
cargo teststill resolveslocally. Five needed it, not the three first identified: the edge
aimdb-tokio-adapter -> aimdb-clientappears in four of the fiveelementary cycles, and
aimdb-embassy-adapter -> aimdb-core = "1.1.0"would have built the packaged tests against the previously published core
rather than the code being released. Conversely,
aimdb-websocket-connector -> aimdb-tokio-adapterforms no cycle —nothing reaches the websocket connector from the tokio adapter — but it
carries the same stale-version hazard and is fixed on that basis.
Also mark
remote-access-demoaspublish = false. It was the onlyexample crate missing the flag, which left it as a 20th publishable crate
that no publish list mentioned.
Verified: the target runs end to end against a stubbed
cargo, emitting19 publishes in the listed order with
--no-verifyon exactly the twointended crates, and aborting on the first failure;
cargo metadatareports no versioned workspace-internal dev-dependencies remain and the
list matches the publishable set exactly; the packaged-manifest behaviour
was reproduced on a scratch workspace, whose
.cratecarries an empty[dev-dependencies]section; andcargo check --all-targetspasses forevery affected crate.
make publishis still not runnable end to end:aimdb-embassy-adapterneeds embassy-sync's
poll_next_message/poll_changed, which aremerged upstream but absent from the released 0.8.0 and supplied locally
through
[patch.crates-io]. That is recorded onPUBLISH_NO_VERIFYandis the remaining blocker.
Refs #242
Co-Authored-By: Claude Opus 5 noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01GgvcFC4S8Kii5H6xzW56mi