Vendor rainix-static through fetchCargoVendor: crates.io/api now 403s nix - #369
Conversation
cargoLock fetches each crate from crates.io/api, which now answers 403 to the User-Agent nix sends, so any store miss fails sol-shell entry. fetchCargoVendor pulls from the static.crates.io CDN, the shape the cargo-release override already uses. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EyWWorieTJV9FmMm2JM6Ua
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe ChangesRust dependency vendor source
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to The static package now vendors its pinned Rust dependencies through the CDN-backed source, and the supplied build and runtime validation indicates it is ready to merge. Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
Full details: Docstring CoverageExplanation No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0 files. (1 skipped: 1 unsupported.) ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@coderabbitai assess this PR size classification for the totality of the PR with the following criterias and report it in your comment: S/M/L PR Classification Guidelines:This guide helps classify merged pull requests by effort and complexity rather than just line count. The goal is to assess the difficulty and scope of changes after they have been completed. Small (S)Characteristics:
Review Effort: Would have taken 5-10 minutes Examples:
Medium (M)Characteristics:
Review Effort: Would have taken 15-30 minutes Examples:
Large (L)Characteristics:
Review Effort: Would have taken 45+ minutes Examples:
Additional Factors to ConsiderWhen deciding between sizes, also consider:
Notes:
|
git-clean entered the sol-shell through a rainix-static build whose crate fetch crates.io now refuses; rainix#369 moved it to the static CDN. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EyWWorieTJV9FmMm2JM6Ua
rainix-staticvendors its crates throughcargoLock, andcargoLockin the pinned nixpkgs fetches every crate fromhttps://crates.io/api/v1/crates/<name>/<version>/download. crates.io now answers 403 to thecurl/… Nixpkgs/…User-Agent nix sends there, so any job whose store lacks a crate (acache-nix-actionmiss, or a crate cache.nixos.org never had, likezip-2.4.2) fails to enter the sol-shell at all.git-cleanin S01-Issuer/st0x.deploy has failed on every branch since 2026-08-31 with exactly this; the sibling jobs pass only when their cache restores the vendored crate.The
cargo-releaseoverride a few lines up already works around the same gate for its own source withfetchCrate { url = "https://static.crates.io/…" }andfetchCargoVendor. This PR givesrainix-staticthe second half of that shape:cargoDeps = pkgs.rustPlatform.fetchCargoVendor { src = ./rainix-static; … }, which the pinned nixpkgs already points at thestatic.crates.ioCDN. Nothing in rainix names a URL.Probed from the same host, same crate:
crates.io/api/v1/crates/zip/2.4.2/downloadstatic.crates.io/crates/zip/2.4.2/downloadQA
nix build /nix/store/…-crate-zip-2.4.2.tar.gz.drv^out --rebuildonmaintrieshttps://crates.io/api/v1/crates/zip/2.4.2/downloadand getscurl: (22) … 403four times, the CI failure verbatim.nix build .#rainix-static -Lcompletes, the vendor fixed-output derivation downloads and hashes (sha256-2ZCPiTO11UhhWUAhn3C433VrLfOB+Dlld/B4wh14DXY=, taken from thehash mismatchline of alib.fakeHashbuild, not typed), the build'sdoCheckruns the crate's 203 unit tests green, andnix run .#rainix-staticprints its subcommand list.mainand cannot be reached on this branch because the crate no longer goes through that derivation.fakeHashrun is that mutation, killed withhash mismatch).fetch-cargo-vendor-util-v2.py(static.crates.ioon line 74) andimport-cargo-lock.nix(crates.io/api/v1/crateson line 133) at the pinned revision.rainix-static;cargo-releasealready was. No othercargoLockuse remains in the flake.🤖 Generated with Claude Code
https://claude.ai/code/session_01EyWWorieTJV9FmMm2JM6Ua
Summary by CodeRabbit