Skip to content

Commit

Permalink
fix flake8 not liking bare except
Browse files Browse the repository at this point in the history
  • Loading branch information
teovin committed Sep 23, 2024
1 parent 4269825 commit e20d975
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions perma_web/perma/celery_tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -1594,7 +1594,7 @@ def warn_expiring_sponsored_users(warning_days=None):
}
try:
email_expiring_user(sponsorship.user, "email/sponsored_user_expiry_notification.txt", context)
except:
except Exception:
logger.exception(f"Error emailing user {sponsorship.id}")
break

Expand Down Expand Up @@ -1628,6 +1628,6 @@ def warn_expiring_organization_users(warning_days=None):
}
try:
email_expiring_user(affiliation.user, "email/organization_user_expiry_notification.txt", context)
except:
except Exception:
logger.exception(f"Error emailing user {affiliation.user_id}")
break

0 comments on commit e20d975

Please sign in to comment.