Merge pull request #571 from kquick/moreinfo
Additional helpful information in error messages.
This commit is contained in:
commit
8a41ea5f60
|
@ -56,7 +56,7 @@ sub updateDeclarativeJobset {
|
||||||
$input->jobsetinputalts->create({altnr => 0, value => $data->{value}});
|
$input->jobsetinputalts->create({altnr => 0, value => $data->{value}});
|
||||||
}
|
}
|
||||||
delete $declSpec->{"inputs"};
|
delete $declSpec->{"inputs"};
|
||||||
die "invalid keys in declarative specification file\n" if (%{$declSpec});
|
die "invalid keys ($declSpec) in declarative specification file\n" if (%{$declSpec});
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -425,7 +425,13 @@ sub run {
|
||||||
sub grab {
|
sub grab {
|
||||||
my (%args) = @_;
|
my (%args) = @_;
|
||||||
my $res = run(%args, grabStderr => 0);
|
my $res = run(%args, grabStderr => 0);
|
||||||
die "command `@{$args{cmd}}' failed with exit status $res->{status}" if $res->{status};
|
if ($res->{status}) {
|
||||||
|
my $msgloc = "(in an indeterminate location)";
|
||||||
|
if (defined $args{dir}) {
|
||||||
|
$msgloc = "in $args{dir}";
|
||||||
|
}
|
||||||
|
die "command `@{$args{cmd}}' failed with exit status $res->{status} $msgloc";
|
||||||
|
}
|
||||||
return $res->{stdout};
|
return $res->{stdout};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue