aboutsummaryrefslogtreecommitdiff
path: root/statustracker.py
diff options
context:
space:
mode:
authorTom Ritter <tom@ritter.vg>2016-01-26 01:15:03 -0500
committerTom Ritter <tom@ritter.vg>2016-01-26 01:15:03 -0500
commit869de79cc6483f5583b2f9bddd08720d103c8bec (patch)
tree1d548222a4b8d142ff821898df59786c24b176ae /statustracker.py
parent19341244fb0a313a1743cbae9c3dc5cbbcd3ddb0 (diff)
Differentiating between a mail problem and jobs not being run.
Diffstat (limited to 'statustracker.py')
-rwxr-xr-xstatustracker.py10
1 files changed, 6 insertions, 4 deletions
diff --git a/statustracker.py b/statustracker.py
index 2c3350c..d092266 100755
--- a/statustracker.py
+++ b/statustracker.py
@@ -11,12 +11,14 @@ class StatusTracker:
self.lastRunJob = 0
self.config = config
- def isAllGood(self):
- return self.emailNotificationsAreWorking and \
- time.time() - self.lastRunJob < 120
+ def isMailGood(self):
+ return self.emailNotificationsAreWorking
+
+ def isJobsGood(self):
+ return time.time() - self.lastRunJob < 120
def markJobRan(self):
self.lastRunJob = time.time()
def markEmailStatus(self, working):
- self.emailNotificationsAreWorking = working \ No newline at end of file
+ self.emailNotificationsAreWorking = working