From aa6574218af65537fb702bb5af901c105c56bd99 Mon Sep 17 00:00:00 2001 From: Sander Roosendaal Date: Tue, 31 Oct 2017 20:55:22 +0100 Subject: [PATCH] removed try except around email in tasks.py --- rowers/tasks.py | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/rowers/tasks.py b/rowers/tasks.py index 1427f0f9..237f9be4 100644 --- a/rowers/tasks.py +++ b/rowers/tasks.py @@ -382,13 +382,10 @@ def handle_otwsetpower(f1, boattype, weightvalue, res, btvalues, res2 = utils.isbreakthrough( delta, cpvalues, ps[0], ps[1], ps[2], ps[3], ratio) if res: - try: - handle_sendemail_breakthrough( - workoutid, email, - first_name, - last_name, btvalues=btvalues.to_json()) - except: - pass + handle_sendemail_breakthrough( + workoutid, email, + first_name, + last_name, btvalues=btvalues.to_json()) # send email fullemail = first_name + " " + last_name + " " + "<" + email + ">" @@ -404,12 +401,9 @@ def handle_otwsetpower(f1, boattype, weightvalue, message += "Please report any bugs/inconsistencies/unexpected results at rowsandall.slack.com or by reply to this email.\n\n" message += "Best Regards, The Rowsandall Physics Department." - try: - send_mail(subject, message, + send_mail(subject, message, 'Rowsandall Physics Department ', [fullemail]) - except: - return 0 return 1