aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDamien Lespiau <damien.lespiau@intel.com>2015-10-09 11:22:54 +0100
committerStephen Finucane <stephen.finucane@intel.com>2015-10-27 02:04:01 +0000
commitf0b88868e26bd24c1676caefe389d4865ede7089 (patch)
treedee49d5aad7966e272c14dc9ee6c44d0b415a31e
parent4fa548ca4f29ebbe0d380509f77b397d82ece464 (diff)
downloadpatchwork-f0b88868e26bd24c1676caefe389d4865ede7089.tar
patchwork-f0b88868e26bd24c1676caefe389d4865ede7089.tar.gz
parsemail: Don't catch exceptions when saving patches and comments
We'd like to know when those operations fail in production so we can at least inspect what happened through the email send to settings.ADMINS in main(). Catching those exceptions early prevents that. Signed-off-by: Damien Lespiau <damien.lespiau@intel.com> Acked-by: Stephen Finucane <stephen.finucane@intel.com>
-rwxr-xr-xpatchwork/bin/parsemail.py10
1 files changed, 2 insertions, 8 deletions
diff --git a/patchwork/bin/parsemail.py b/patchwork/bin/parsemail.py
index 84ab685..c15564e 100755
--- a/patchwork/bin/parsemail.py
+++ b/patchwork/bin/parsemail.py
@@ -384,10 +384,7 @@ def parse_mail(mail):
patch.state = get_state(mail.get('X-Patchwork-State', '').strip())
patch.delegate = get_delegate(
mail.get('X-Patchwork-Delegate', '').strip())
- try:
- patch.save()
- except Exception, ex:
- print str(ex)
+ patch.save()
if comment:
if save_required:
@@ -397,10 +394,7 @@ def parse_mail(mail):
comment.patch = patch
comment.submitter = author
comment.msgid = msgid
- try:
- comment.save()
- except Exception, ex:
- print str(ex)
+ comment.save()
return 0