-
Notifications
You must be signed in to change notification settings - Fork 2.8k
fix(vendor): unpack from local-registry cache path #16435
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Conversation
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
Collaborator
epage
reviewed
Dec 26, 2025
epage
reviewed
Dec 26, 2025
epage
reviewed
Dec 26, 2025
This is a minimal reproducible example of rust-lang#16412
In rust-lang#15514, Cargo starts direct-extraction from `.crate` tarball in `$CARGO_HOME/registry/cache` when vendoring. This is fine with remote registrires but not for local registries, as local registries' tarball are stored along with index. This fix abstracts `cache_path` to `RegistryData` trait, so every registry source type can define its own locationa of tarball cache. Note that for local-registry when accessing either index or cache, the assumption is that file lock of the index and cache directory need to be externally synchronized. Cargo doesn't take care of it.
e74a3a5 to
c7f10b7
Compare
epage
approved these changes
Dec 26, 2025
bors
added a commit
to rust-lang/rust
that referenced
this pull request
Dec 27, 2025
Update cargo submodule 17 commits in e91b2baa632c0c7e84216c91ecfe107c37d887c1..94c368ad2b9db0f0da5bdd8421cea13786ce4412 2025-12-13 16:29:21 +0000 to 2025-12-26 19:39:15 +0000 - fix(vendor): unpack from local-registry cache path (rust-lang/cargo#16435) - feat(index): Stabilize pubtime (rust-lang/cargo#16372) - Experiment: Render timing pipeline in SVG (rust-lang/cargo#15091) - chore(triagebot): auto-label `Command-report` (rust-lang/cargo#16429) - fix(sbom): Don't set CARGO_SBOM_PATH when empty (like stable) (rust-lang/cargo#16419) - chore(ci): report-timings to upload HTML report (rust-lang/cargo#16416) - fix(report): get the same feature parity of `--timings` (rust-lang/cargo#16414) - fix(docs): Document the only possible values for DEBUG in build scripts (rust-lang/cargo#16413) - fix(log): emit fingeprint log also for no-rebuild unit (rust-lang/cargo#16408) - Fix link to `doc_cfg` docs in cargo book (rust-lang/cargo#16404) - Add best pratice for how to check in generated files (rust-lang/cargo#16405) - test: Use a larger default term width (rust-lang/cargo#16403) - Document more services and permissions of the cargo team (rust-lang/cargo#16402) - fix(new): Improve quality of package name error messages (rust-lang/cargo#16398) - feat(log): add more log events (rust-lang/cargo#16390) - chore: bump to 0.95.0; update changelog (rust-lang/cargo#16395) - Cache submodule into git db (rust-lang/cargo#16246) r? ghost
github-actions bot
pushed a commit
to rust-lang/compiler-builtins
that referenced
this pull request
Dec 28, 2025
Update cargo submodule 17 commits in e91b2baa632c0c7e84216c91ecfe107c37d887c1..94c368ad2b9db0f0da5bdd8421cea13786ce4412 2025-12-13 16:29:21 +0000 to 2025-12-26 19:39:15 +0000 - fix(vendor): unpack from local-registry cache path (rust-lang/cargo#16435) - feat(index): Stabilize pubtime (rust-lang/cargo#16372) - Experiment: Render timing pipeline in SVG (rust-lang/cargo#15091) - chore(triagebot): auto-label `Command-report` (rust-lang/cargo#16429) - fix(sbom): Don't set CARGO_SBOM_PATH when empty (like stable) (rust-lang/cargo#16419) - chore(ci): report-timings to upload HTML report (rust-lang/cargo#16416) - fix(report): get the same feature parity of `--timings` (rust-lang/cargo#16414) - fix(docs): Document the only possible values for DEBUG in build scripts (rust-lang/cargo#16413) - fix(log): emit fingeprint log also for no-rebuild unit (rust-lang/cargo#16408) - Fix link to `doc_cfg` docs in cargo book (rust-lang/cargo#16404) - Add best pratice for how to check in generated files (rust-lang/cargo#16405) - test: Use a larger default term width (rust-lang/cargo#16403) - Document more services and permissions of the cargo team (rust-lang/cargo#16402) - fix(new): Improve quality of package name error messages (rust-lang/cargo#16398) - feat(log): add more log events (rust-lang/cargo#16390) - chore: bump to 0.95.0; update changelog (rust-lang/cargo#16395) - Cache submodule into git db (rust-lang/cargo#16246) r? ghost
github-actions bot
pushed a commit
to rust-lang/miri
that referenced
this pull request
Dec 28, 2025
Update cargo submodule 17 commits in e91b2baa632c0c7e84216c91ecfe107c37d887c1..94c368ad2b9db0f0da5bdd8421cea13786ce4412 2025-12-13 16:29:21 +0000 to 2025-12-26 19:39:15 +0000 - fix(vendor): unpack from local-registry cache path (rust-lang/cargo#16435) - feat(index): Stabilize pubtime (rust-lang/cargo#16372) - Experiment: Render timing pipeline in SVG (rust-lang/cargo#15091) - chore(triagebot): auto-label `Command-report` (rust-lang/cargo#16429) - fix(sbom): Don't set CARGO_SBOM_PATH when empty (like stable) (rust-lang/cargo#16419) - chore(ci): report-timings to upload HTML report (rust-lang/cargo#16416) - fix(report): get the same feature parity of `--timings` (rust-lang/cargo#16414) - fix(docs): Document the only possible values for DEBUG in build scripts (rust-lang/cargo#16413) - fix(log): emit fingeprint log also for no-rebuild unit (rust-lang/cargo#16408) - Fix link to `doc_cfg` docs in cargo book (rust-lang/cargo#16404) - Add best pratice for how to check in generated files (rust-lang/cargo#16405) - test: Use a larger default term width (rust-lang/cargo#16403) - Document more services and permissions of the cargo team (rust-lang/cargo#16402) - fix(new): Improve quality of package name error messages (rust-lang/cargo#16398) - feat(log): add more log events (rust-lang/cargo#16390) - chore: bump to 0.95.0; update changelog (rust-lang/cargo#16395) - Cache submodule into git db (rust-lang/cargo#16246) r? ghost
github-actions bot
pushed a commit
to rust-lang/rustc-dev-guide
that referenced
this pull request
Dec 29, 2025
Update cargo submodule 17 commits in e91b2baa632c0c7e84216c91ecfe107c37d887c1..94c368ad2b9db0f0da5bdd8421cea13786ce4412 2025-12-13 16:29:21 +0000 to 2025-12-26 19:39:15 +0000 - fix(vendor): unpack from local-registry cache path (rust-lang/cargo#16435) - feat(index): Stabilize pubtime (rust-lang/cargo#16372) - Experiment: Render timing pipeline in SVG (rust-lang/cargo#15091) - chore(triagebot): auto-label `Command-report` (rust-lang/cargo#16429) - fix(sbom): Don't set CARGO_SBOM_PATH when empty (like stable) (rust-lang/cargo#16419) - chore(ci): report-timings to upload HTML report (rust-lang/cargo#16416) - fix(report): get the same feature parity of `--timings` (rust-lang/cargo#16414) - fix(docs): Document the only possible values for DEBUG in build scripts (rust-lang/cargo#16413) - fix(log): emit fingeprint log also for no-rebuild unit (rust-lang/cargo#16408) - Fix link to `doc_cfg` docs in cargo book (rust-lang/cargo#16404) - Add best pratice for how to check in generated files (rust-lang/cargo#16405) - test: Use a larger default term width (rust-lang/cargo#16403) - Document more services and permissions of the cargo team (rust-lang/cargo#16402) - fix(new): Improve quality of package name error messages (rust-lang/cargo#16398) - feat(log): add more log events (rust-lang/cargo#16390) - chore: bump to 0.95.0; update changelog (rust-lang/cargo#16395) - Cache submodule into git db (rust-lang/cargo#16246) r? ghost
Kobzol
pushed a commit
to Kobzol/rustc_codegen_cranelift
that referenced
this pull request
Dec 29, 2025
Update cargo submodule 17 commits in e91b2baa632c0c7e84216c91ecfe107c37d887c1..94c368ad2b9db0f0da5bdd8421cea13786ce4412 2025-12-13 16:29:21 +0000 to 2025-12-26 19:39:15 +0000 - fix(vendor): unpack from local-registry cache path (rust-lang/cargo#16435) - feat(index): Stabilize pubtime (rust-lang/cargo#16372) - Experiment: Render timing pipeline in SVG (rust-lang/cargo#15091) - chore(triagebot): auto-label `Command-report` (rust-lang/cargo#16429) - fix(sbom): Don't set CARGO_SBOM_PATH when empty (like stable) (rust-lang/cargo#16419) - chore(ci): report-timings to upload HTML report (rust-lang/cargo#16416) - fix(report): get the same feature parity of `--timings` (rust-lang/cargo#16414) - fix(docs): Document the only possible values for DEBUG in build scripts (rust-lang/cargo#16413) - fix(log): emit fingeprint log also for no-rebuild unit (rust-lang/cargo#16408) - Fix link to `doc_cfg` docs in cargo book (rust-lang/cargo#16404) - Add best pratice for how to check in generated files (rust-lang/cargo#16405) - test: Use a larger default term width (rust-lang/cargo#16403) - Document more services and permissions of the cargo team (rust-lang/cargo#16402) - fix(new): Improve quality of package name error messages (rust-lang/cargo#16398) - feat(log): add more log events (rust-lang/cargo#16390) - chore: bump to 0.95.0; update changelog (rust-lang/cargo#16395) - Cache submodule into git db (rust-lang/cargo#16246) r? ghost
github-actions bot
pushed a commit
to rust-lang/stdarch
that referenced
this pull request
Jan 1, 2026
Update cargo submodule 17 commits in e91b2baa632c0c7e84216c91ecfe107c37d887c1..94c368ad2b9db0f0da5bdd8421cea13786ce4412 2025-12-13 16:29:21 +0000 to 2025-12-26 19:39:15 +0000 - fix(vendor): unpack from local-registry cache path (rust-lang/cargo#16435) - feat(index): Stabilize pubtime (rust-lang/cargo#16372) - Experiment: Render timing pipeline in SVG (rust-lang/cargo#15091) - chore(triagebot): auto-label `Command-report` (rust-lang/cargo#16429) - fix(sbom): Don't set CARGO_SBOM_PATH when empty (like stable) (rust-lang/cargo#16419) - chore(ci): report-timings to upload HTML report (rust-lang/cargo#16416) - fix(report): get the same feature parity of `--timings` (rust-lang/cargo#16414) - fix(docs): Document the only possible values for DEBUG in build scripts (rust-lang/cargo#16413) - fix(log): emit fingeprint log also for no-rebuild unit (rust-lang/cargo#16408) - Fix link to `doc_cfg` docs in cargo book (rust-lang/cargo#16404) - Add best pratice for how to check in generated files (rust-lang/cargo#16405) - test: Use a larger default term width (rust-lang/cargo#16403) - Document more services and permissions of the cargo team (rust-lang/cargo#16402) - fix(new): Improve quality of package name error messages (rust-lang/cargo#16398) - feat(log): add more log events (rust-lang/cargo#16390) - chore: bump to 0.95.0; update changelog (rust-lang/cargo#16395) - Cache submodule into git db (rust-lang/cargo#16246) r? ghost
github-actions bot
pushed a commit
to rust-lang/rust-analyzer
that referenced
this pull request
Jan 8, 2026
Update cargo submodule 17 commits in e91b2baa632c0c7e84216c91ecfe107c37d887c1..94c368ad2b9db0f0da5bdd8421cea13786ce4412 2025-12-13 16:29:21 +0000 to 2025-12-26 19:39:15 +0000 - fix(vendor): unpack from local-registry cache path (rust-lang/cargo#16435) - feat(index): Stabilize pubtime (rust-lang/cargo#16372) - Experiment: Render timing pipeline in SVG (rust-lang/cargo#15091) - chore(triagebot): auto-label `Command-report` (rust-lang/cargo#16429) - fix(sbom): Don't set CARGO_SBOM_PATH when empty (like stable) (rust-lang/cargo#16419) - chore(ci): report-timings to upload HTML report (rust-lang/cargo#16416) - fix(report): get the same feature parity of `--timings` (rust-lang/cargo#16414) - fix(docs): Document the only possible values for DEBUG in build scripts (rust-lang/cargo#16413) - fix(log): emit fingeprint log also for no-rebuild unit (rust-lang/cargo#16408) - Fix link to `doc_cfg` docs in cargo book (rust-lang/cargo#16404) - Add best pratice for how to check in generated files (rust-lang/cargo#16405) - test: Use a larger default term width (rust-lang/cargo#16403) - Document more services and permissions of the cargo team (rust-lang/cargo#16402) - fix(new): Improve quality of package name error messages (rust-lang/cargo#16398) - feat(log): add more log events (rust-lang/cargo#16390) - chore: bump to 0.95.0; update changelog (rust-lang/cargo#16395) - Cache submodule into git db (rust-lang/cargo#16246) r? ghost
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-local-registry-source
Area: local registry sources (vendoring)
A-registries
Area: registries
A-sparse-registry
Area: http sparse registries
Command-vendor
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.
What does this PR try to resolve?
In #15514, Cargo starts direct-extraction from
.cratetarball in
$CARGO_HOME/registry/cachewhen vendoring. This is fine withremote registrires but not for local registries, as local registries'
tarball are stored along with index.
This fix abstracts
cache_pathtoRegistryDatatrait, so everyregistry source type can define its own locationa of tarball cache.
Note that for local-registry when accessing either index or cache, the
assumption is that file lock of the index and cache directory need to
be externally synchronized. Cargo doesn't take care of it.
Fixes #16412
How to test and review this PR?