Skip to content

k3s.tests: fix eval#412756

Merged
marcusramberg merged 1 commit intoNixOS:masterfrom
numinit:k3s/fix-passthru-tests
May 31, 2025
Merged

k3s.tests: fix eval#412756
marcusramberg merged 1 commit intoNixOS:masterfrom
numinit:k3s/fix-passthru-tests

Conversation

@numinit
Copy link
Contributor

@numinit numinit commented May 31, 2025

The k3s tests depend on everything in nixosTests.k3s, which depend on all the k3s versions using tryEval. Just delete the recurseIntoAttrs to prevent this error:

$ nix-instantiate -A k3s.tests
error:
       … while evaluating the attribute 'recurseForDerivations'

       … while selecting an attribute
         at pkgs/applications/networking/cluster/k3s/builder.nix:487:36:
          486|         in
          487|         lib.mapAttrs (name: value: nixosTests.k3s.${name}.${k3s_version}) nixosTests.k3s;
             |                                    ^
          488|       tests = passthru.mkTests k3sVersion;

       error: expected a set but found a Boolean: true

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • Nixpkgs 25.11 Release Notes (or backporting 24.11 and 25.05 Nixpkgs Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
  • NixOS 25.11 Release Notes (or backporting 24.11 and 25.05 NixOS Release notes)
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

@numinit numinit added 3.skill: trivial This is trivial to complete (typically find-and-replace) backport release-25.05 labels May 31, 2025
@github-actions github-actions bot added 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 6.topic: k3s Kubernates distribution (https://k3s.io/) labels May 31, 2025
@numinit numinit mentioned this pull request May 31, 2025
13 tasks
@github-actions github-actions bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux. labels May 31, 2025
@marcusramberg marcusramberg merged commit 203d846 into NixOS:master May 31, 2025
20 of 23 checks passed
@nixpkgs-ci
Copy link
Contributor

nixpkgs-ci bot commented May 31, 2025

Successfully created backport PR for release-25.05:

@github-actions github-actions bot added the 8.has: port to stable This PR already has a backport to the stable release. label May 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3.skill: trivial This is trivial to complete (typically find-and-replace) 6.topic: k3s Kubernates distribution (https://k3s.io/) 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: port to stable This PR already has a backport to the stable release. 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants