Repository navigation
fix(ci): include flake.lock in rust-cache key - #160
Merged
Merged
Conversation
When a consumer upgrades nixpkgs while keeping rust-toolchain.toml pinned, Swatinem/rust-cache@v2 restores the previous NixOS release target/ directory because Cargo.lock and rustc -Vv are unchanged. Cached build-script binaries then fail on Linux with ENOENT due to stale /nix/store glibc PT_INTERP paths.
Include hashFiles('flake.lock') in the rust-cache key for both the main and MSRV jobs so Nix toolchain or glibc changes invalidate the Cargo cache.
4 tasks done
hakula139
added a commit
that referenced
this pull request
Dec 6, 2026
## Summary Prepare `v3.10.2` release notes in `CHANGELOG.md` and restore the documented minimum `nixpkgs` version in `docs/flake.md` to `26.05`, since this patch release introduces no breaking changes for `26.05` callers while devkit's own `flake.nix` stays on `nixos-26.11`. - **ci**: `setup-nix` uses `cachix/cachix-action` v18, which installs a pinned Cachix CLI version (#157) - **flake**: `devkit`'s default `nixpkgs` input tracks `nixos-26.11`, while downstream repositories using `inputs.nixpkgs.follows` are unaffected and the minimum supported `nixpkgs` release remains `26.05` (#158) - **ci**: `rust.yml` includes `flake.lock` in the `Swatinem/rust-cache` key for both `rust` and `msrv` jobs (#160) ## Test plan - [x] `nix run .#changelog -- v3.10.2` generated the draft from `v3.10.1` - [x] `nix develop -c run-hooks` passed (all 21 hooks) - [x] `nix flake check --all-systems` passed - [x] Commit and pre-push hooks passed ## Related - Refs hakulab/nixos-config#659
24 of 31 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.
Summary
key: ${{ hashFiles('flake.lock') }}in bothSwatinem/rust-cache@v2steps (rustandmsrvjobs) in.github/workflows/rust.yml.rust-toolchain.tomlpinned,Swatinem/rust-cache@v2previously restored the old NixOS release'starget/directory becauseCargo.lockandrustc -Vvwere unchanged, causing cached build-script binaries to fail on Linux withENOENTdue to stale/nix/storeglibcPT_INTERPpaths.flake.lockto thekeyinput isolates both primary and restore keys across Nix input updates.Test plan
nix develop -c run-hooks(all 21 hooks passed, includingactionlintandcheck-yaml)nix flake check --all-systems(all checks passed)Related