Retire submodules - #221
Merged
Merged
Conversation
… Cargo.toml files
…dencies in Cargo.toml
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.
Retires two of the three
_external/submodules and cuts the[patch.crates-io]block from five entries to three.
Why
aimdb-knx-connectorandaimdb-mqtt-connectordepended on vendored forks ofknx-picoandmountain-mqttthrough[patch.crates-io]. That works inside thisworkspace and nowhere else: a patch is workspace-local and is stripped from a
published manifest, so any downstream consumer resolved to the upstream crate
instead. Both forks also carried the same name and version as a live upstream
release, so there was no version number that could mean "the fork".
The consequences differed by crate, and one of them was not a latent bug:
knx-pico 0.3.0npdu_length=1telegrammountain-mqtt 0.2.0ConnectionSettings::authenticated, called byembassy_client.rsGit dependencies do not fix this either:
cargorefuses to package agitdependencywith no
version, and if you add one it packages happily while deleting the gitspecification.
What changed
The forks are now published under names we own and are consumed from crates.io:
aimdb-knx-pico 0.3.1aimdb-mountain-mqtt 0.2.1aimdb-mountain-mqtt-embassy 0.2.1Each is declared with a
packagealias, so no Rust source changed:The left-hand key is unchanged, which keeps
use knx_pico::…and theknx-pico/*feature references working. With no
pathalongside,Cargo.locknow recordssource = "registry+…crates.io-index"— this workspace compiles the same artifact aconsumer gets, which was the entire point.
_external/knx-picoand_external/mountain-mqttare deregistered. The forkcheckouts live beside the other repos in
aimdb-dev.code-workspaceand are onlyneeded when working on a fork.
Embassy: reduced, not retired
_external/embassystays, and the patch block keeps three entries:aimdb-embassy-adapter/src/buffer.rscallsSubscriber::poll_next_messageandReceiver::poll_changed, which are merged upstream but absent from the releasedembassy-sync 0.8.0. The two driver crates follow because publishedembassy-net-driver-channel 0.4.0calls a pre-guardzerocopy_channelAPI the patchedembassy-syncno longer has, and its driver trait must be the same instanceembassy-netsees.Everything else —
embassy-executor,embassy-time,embassy-net,embassy-futures,embassy-stm32— now resolves from crates.io at the declaredversions.
This leaves a known gap.
aimdb-embassy-adaptercannot be honestly published untilan Embassy release carries those APIs, and the failure is quiet: the crate is
default = ["alloc"], socargo publish's verify build never reaches the affectedcode, and
make publishpasses--no-verifyfor it anyway. Tracked as a release gate,not fixed here. When the release lands, the patch block and the submodule go together.
Notes for reviewers
cargoresolves one graph per workspace, so amissing
_external/embassybreaks every member, not just the embassy ones. CI needssubmodules: recursive.then bump the requirement in the consuming connector. The middle step is easy to skip,
because nothing local breaks if you do.
Cargo.lockand submodule registration.Verified
make checklocally, plus targeted builds after the submodule removal: the KNXconnector on tokio, the MQTT connector with
embassy-runtimecross-compiled tothumbv7em-none-eabihf, and the siblingaimdb-weather-meshworkspace, which consumesthese connectors by path and is not covered by this repo's CI.