From 65e71a10d23a70cd9dfdd6922b87802ad72f4eac Mon Sep 17 00:00:00 2001 From: Tom Ritter Date: Mon, 25 Jan 2016 22:34:02 -0500 Subject: Log an exception if we can't send email. --- jobs/JobBase.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/jobs/JobBase.py b/jobs/JobBase.py index 330b6a9..e7b3c33 100755 --- a/jobs/JobBase.py +++ b/jobs/JobBase.py @@ -49,5 +49,6 @@ def sendEmail(config, subject, body, to=""): server.sendmail(FROM, to, message) server.close() return True - except: - return False \ No newline at end of file + except Exception as e: + logging.critical("Caught an exception trying to send an email:" + str(e)) + return False -- cgit v1.2.3