Repository navigation
fix(rust): name a member NAME@VERSION when a dependency shares its name - #232
Merged
adityankale190895 merged 2 commits intoNov 18, 2026
Merged
Conversation
I, FredApps <[email protected]>, hereby add my Signed-off-by to this commit: 9e06c4b Signed-off-by: FredApps <[email protected]>
This was referenced Nov 18, 2026
Merged
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.
Fixes #224
A workspace member whose name another package in the metadata also uses (an older release of itself, say) is now named
NAME@VERSIONeverywhere the adapter hands it to Cargo:testPackages, thecargo tree -punits and the feature coverage keys. The planner accepts[email protected][-pre]as a literal argument. It still refuses ranges, partial versions,+buildand anything with spaces. A member with a unique name keeps the bare name, so existing plans don't change.If the version can't tell them apart (missing, or the same as the dependency's), the repository falls back with a new reason, documented in
docs/using-diffci.md:Cargo package … has no unambiguous package specification; full validation required.Tests:
dup0.2.0 depends on a local Gitdup0.1.0 withdefault-features = false, socargo treeruns, and the synthesizedcargo test -p [email protected]passes. It's skipped without Cargo or Git.Validation (Linux, Node 22, Cargo 1.100):
npm run typecheckand the Rust test files (tests/repo/rust-*.test.ts,tests/planner/rust-command.test.ts) pass. The new test fails onmainand passes here.tests/fallback-reasons-docs.test.tspasses too.Not changed:
parseCargoFeatureTreestill keys packages byname vX.Y.Z. Two packages with the same name and version from different sources would share a key. I left that alone because it's much rarer, and the new fallback already covers it for workspace members.Merge order (#131 series: #232, #234, #248, #250, #252, #254, #256, #277, #258). These all edit the one-line Rust paragraph in
docs/using-diffci.md, and some also touchrust.ts/types.ts, so they conflict textually with each other. #258 already includes #232, #248, #250 and #254 with those conflicts resolved. The simplest path: merge #258 (GitHub marks those four as merged), then #234, #252, #256 and #277. After each one lands I mergemaininto the next and resolve the docs line. Merging them one at a time in number order works too, with the samemainmerge after each.