aboutsummaryrefslogtreecommitdiff
path: root/src/libcmd/installables.cc
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2023-01-05 15:32:04 +0100
committerGitHub <noreply@github.com>2023-01-05 15:32:04 +0100
commit0fe2b222d513ad261c4afb33f53ee131e615e49a (patch)
treec0067859a412679b3910b76c28528c0a1a8fbf81 /src/libcmd/installables.cc
parentd644b456159b0335039666f6620a9f3d8129a83a (diff)
parent8cac451fce990151046996a13130bb1b91c6ba19 (diff)
Merge pull request #7539 from tweag/fix-nix-why-depends--derivation
Fix `nix why-depends --derivation`
Diffstat (limited to 'src/libcmd/installables.cc')
-rw-r--r--src/libcmd/installables.cc5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/libcmd/installables.cc b/src/libcmd/installables.cc
index f481a41a0..79361e94e 100644
--- a/src/libcmd/installables.cc
+++ b/src/libcmd/installables.cc
@@ -931,10 +931,7 @@ std::vector<std::pair<std::shared_ptr<Installable>, BuiltPathWithResult>> Instal
DrvOutput outputId { *outputHash, output };
auto realisation = store->queryRealisation(outputId);
if (!realisation)
- throw Error(
- "cannot operate on an output of the "
- "unbuilt derivation '%s'",
- outputId.to_string());
+ throw MissingRealisation(outputId);
outputs.insert_or_assign(output, realisation->outPath);
} else {
// If ca-derivations isn't enabled, assume that