fix logger.exception syntax

when given any log function with multiple parameters, the python logging utils
assume the first param is a format string and the rest are arguments to pass
in - we were passing in the exception object to `logger.exception`, however,
the purpose of .exception is to add the exception object itself - so we didn't
need to
This commit is contained in:
Leo Hemsted
2016-10-17 17:44:17 +01:00
parent 65197a6c91
commit a1cc092d3b
2 changed files with 6 additions and 6 deletions

View File

@@ -309,7 +309,7 @@ def persist_notification(
queue='send-email' if not research_mode else 'research-mode'
)
except Exception as e:
current_app.logger.exception("Failed to send to SQS exception", e)
current_app.logger.exception("Failed to send to SQS exception")
dao_delete_notifications_and_history_by_id(notification_id)
raise InvalidRequest(message="Internal server error", status_code=500)