Only send email notification of evaluation error when the evaluation error has changed. Fixes #121.
This commit is contained in:
parent
550d6b79b1
commit
b1e29e50a7
@ -41,13 +41,17 @@ sub fetchInputs {
|
|||||||
|
|
||||||
sub setJobsetError {
|
sub setJobsetError {
|
||||||
my ($jobset, $errorMsg) = @_;
|
my ($jobset, $errorMsg) = @_;
|
||||||
|
my $prevError = $jobset->errormsg;
|
||||||
|
|
||||||
eval {
|
eval {
|
||||||
txn_do($db, sub {
|
txn_do($db, sub {
|
||||||
$jobset->update({errormsg => $errorMsg, errortime => time});
|
$jobset->update({errormsg => $errorMsg, errortime => time});
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
if ($errorMsg ne $prevError) {
|
||||||
sendJobsetErrorNotification($jobset, $errorMsg);
|
sendJobsetErrorNotification($jobset, $errorMsg);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
sub sendJobsetErrorNotification() {
|
sub sendJobsetErrorNotification() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user