From 771911a16edf7a0a35be8318ed5162ec1d44ca14 Mon Sep 17 00:00:00 2001 From: Nick Cao Date: Mon, 7 Feb 2022 18:03:35 +0800 Subject: [PATCH 1/2] nixUnstable: pre20220127 -> pre20220221 --- pkgs/tools/package-management/nix/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/tools/package-management/nix/default.nix b/pkgs/tools/package-management/nix/default.nix index ffbe598b9291..af5f00ef7124 100644 --- a/pkgs/tools/package-management/nix/default.nix +++ b/pkgs/tools/package-management/nix/default.nix @@ -66,12 +66,12 @@ in lib.makeExtensible (self: { unstable = lib.lowPrio (common rec { version = "2.7"; - suffix = "pre20220127_${lib.substring 0 7 src.rev}"; + suffix = "pre20220221_${lib.substring 0 7 src.rev}"; src = fetchFromGitHub { owner = "NixOS"; repo = "nix"; - rev = "558c4ee3e370c9f9a6ea293df54ed6914a999f1c"; - sha256 = "sha256-hMzKQflpgf3P7OdYKSnD1VMBSnF48XSRjaNX3bUJct4="; + rev = "caf51729450d4c57d48ddbef8e855e9bf65f8792"; + sha256 = "sha256-2fbza6fWPjyTyVEqWIp0jk/Z4epjSDe1u4lbEu+v7Iw="; }; }); }) From 093070927299b9b31ece0365ac0e82208c081837 Mon Sep 17 00:00:00 2001 From: Nick Cao Date: Tue, 8 Feb 2022 14:08:11 +0800 Subject: [PATCH 2/2] hydra-unstable: fix build with nixVersions.unstable --- pkgs/development/tools/misc/hydra/default.nix | 1 + pkgs/development/tools/misc/hydra/eval.patch | 34 +++++++++++++++++++ 2 files changed, 35 insertions(+) create mode 100644 pkgs/development/tools/misc/hydra/eval.patch diff --git a/pkgs/development/tools/misc/hydra/default.nix b/pkgs/development/tools/misc/hydra/default.nix index 1688e92c8441..27ff31dae963 100644 --- a/pkgs/development/tools/misc/hydra/default.nix +++ b/pkgs/development/tools/misc/hydra/default.nix @@ -9,6 +9,7 @@ rev = "9bce425c3304173548d8e822029644bb51d35263"; sha256 = "sha256-tGzwKNW/odtAYcazWA9bPVSmVXMGKfXsqCA1UYaaxmU="; }; + patches = [ ./eval.patch ]; nix = nixVersions.unstable; tests = { diff --git a/pkgs/development/tools/misc/hydra/eval.patch b/pkgs/development/tools/misc/hydra/eval.patch new file mode 100644 index 000000000000..5e156be16e31 --- /dev/null +++ b/pkgs/development/tools/misc/hydra/eval.patch @@ -0,0 +1,34 @@ +--- a/src/hydra-eval-jobs/hydra-eval-jobs.cc ++++ b/src/hydra-eval-jobs/hydra-eval-jobs.cc +@@ -64,11 +64,11 @@ + + static std::string queryMetaStrings(EvalState & state, DrvInfo & drv, const string & name, const string & subAttribute) + { +- Strings res; ++ list res; + std::function rec; + + rec = [&](Value & v) { +- state.forceValue(v); ++ state.forceValue(v, noPos); + if (v.type() == nString) + res.push_back(v.string.s); + else if (v.isList()) +@@ -112,7 +112,7 @@ + callFlake(state, lockedFlake, *vFlake); + + auto vOutputs = vFlake->attrs->get(state.symbols.create("outputs"))->value; +- state.forceValue(*vOutputs); ++ state.forceValue(*vOutputs, noPos); + + auto aHydraJobs = vOutputs->attrs->get(state.symbols.create("hydraJobs")); + if (!aHydraJobs) +@@ -191,7 +191,7 @@ + state.forceList(*a->value, *a->pos); + for (unsigned int n = 0; n < a->value->listSize(); ++n) { + auto v = a->value->listElems()[n]; +- state.forceValue(*v); ++ state.forceValue(*v, noPos); + if (v->type() == nString) + job["namedConstituents"].push_back(state.forceStringNoCtx(*v)); + }