From 82b06436b4b563a85e70f3fcc610959482f08e91 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 29 May 2022 02:00:01 +0200 Subject: daemon: Clarify ‘--check’ error when outputs are missing. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Drop the confusing ‘invalid’ jargon and display a hint like we do for ‘--fallback’. * nix/libstore/build.cc (DerivationGoal::outputsSubstituted): Rewrite error message. --- nix/libstore/build.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'nix/libstore/build.cc') diff --git a/nix/libstore/build.cc b/nix/libstore/build.cc index 9305208009..006e4ebbbb 100644 --- a/nix/libstore/build.cc +++ b/nix/libstore/build.cc @@ -979,7 +979,7 @@ void DerivationGoal::outputsSubstituted() return; } if (buildMode == bmCheck && nrInvalid > 0) - throw Error(format("some outputs of `%1%' are not valid, so checking is not possible") % drvPath); + throw Error(format("`%1%' is missing outputs; build it normally before using `--check'") % drvPath); /* Otherwise, at least one of the output paths could not be produced using a substitute. So we have to build instead. */ -- cgit v1.2.3 From 0ace58b99c7292dd962bcd244f274f8033a7fce4 Mon Sep 17 00:00:00 2001 From: Tobias Geerinckx-Rice Date: Sun, 5 Jun 2022 02:00:00 +0200 Subject: daemon: Quote consistently within a string. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * nix/libstore/build.cc (DerivationGoal::registerOutput): ‘’ → `'. --- nix/libstore/build.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'nix/libstore/build.cc') diff --git a/nix/libstore/build.cc b/nix/libstore/build.cc index 006e4ebbbb..10a6093bd5 100644 --- a/nix/libstore/build.cc +++ b/nix/libstore/build.cc @@ -2422,7 +2422,7 @@ void DerivationGoal::registerOutputs() if (pathExists(dst)) deletePath(dst); if (rename(actualPath.c_str(), dst.c_str())) throw SysError(format("renaming `%1%' to `%2%'") % actualPath % dst); - throw Error(format("derivation `%1%' may not be deterministic: output `%2%' differs from ‘%3%’") + throw Error(format("derivation `%1%' may not be deterministic: output `%2%' differs from `%3%'") % drvPath % path % dst); } else throw Error(format("derivation `%1%' may not be deterministic: output `%2%' differs") -- cgit v1.2.3