forked from lix-project/nix-eval-jobs
print which derivation failed to evaluate
This commit is contained in:
parent
0f8e80f292
commit
fad244725f
|
@ -203,7 +203,7 @@ struct Drv {
|
||||||
std::map<std::string, std::set<std::string>> inputDrvs;
|
std::map<std::string, std::set<std::string>> inputDrvs;
|
||||||
std::optional<nlohmann::json> meta;
|
std::optional<nlohmann::json> meta;
|
||||||
|
|
||||||
Drv(EvalState &state, DrvInfo &drvInfo) {
|
Drv(std::string &attrPath, EvalState &state, DrvInfo &drvInfo) {
|
||||||
|
|
||||||
auto localStore = state.store.dynamic_pointer_cast<LocalFSStore>();
|
auto localStore = state.store.dynamic_pointer_cast<LocalFSStore>();
|
||||||
|
|
||||||
|
@ -214,7 +214,8 @@ struct Drv {
|
||||||
localStore->printStorePath(*out.second);
|
localStore->printStorePath(*out.second);
|
||||||
}
|
}
|
||||||
} catch (const std::exception &e) {
|
} catch (const std::exception &e) {
|
||||||
throw EvalError("derivation must have valid outputs: %s", e.what());
|
throw EvalError("derivation '%s' does not have valid outputs: %s",
|
||||||
|
attrPath, e.what());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (myArgs.meta) {
|
if (myArgs.meta) {
|
||||||
|
@ -326,7 +327,7 @@ static void worker(ref<EvalState> state, Bindings &autoArgs, AutoCloseFD &to,
|
||||||
|
|
||||||
if (v->type() == nAttrs) {
|
if (v->type() == nAttrs) {
|
||||||
if (auto drvInfo = getDerivation(*state, *v, false)) {
|
if (auto drvInfo = getDerivation(*state, *v, false)) {
|
||||||
auto drv = Drv(*state, *drvInfo);
|
auto drv = Drv(attrPathS, *state, *drvInfo);
|
||||||
reply.update(drv);
|
reply.update(drv);
|
||||||
|
|
||||||
/* Register the derivation as a GC root. !!! This
|
/* Register the derivation as a GC root. !!! This
|
||||||
|
|
Loading…
Reference in a new issue