diff options
Diffstat (limited to 'jobmanager.py')
-rwxr-xr-x | jobmanager.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/jobmanager.py b/jobmanager.py index d77bfb0..e4cb72a 100755 --- a/jobmanager.py +++ b/jobmanager.py @@ -65,7 +65,9 @@ class JobManager: else: #Successful Run logging.info("Execution of " + thisJob.getName() + " succeeded") - if lastRunStatus.CurrentStateSuccess == False and thisJob.notifyOnFailureEvery() == JobBase.JobFailureNotificationFrequency.ONSTATECHANGE: + if lastRunStatus.CurrentStateSuccess == False and \ + thisJob.notifyOnFailureEvery() == JobBase.JobFailureNotificationFrequency.ONSTATECHANGE and \ + lastRunStatus.NumFailures >= thisJob.numberFailuresBeforeNotification(): if not thisJob.onStateChangeSuccess(): emailWorks = False lastRunStatus.markSuccessful() |