mirror of
https://github.com/GSA/notifications-api.git
synced 2026-02-04 02:11:11 -05:00
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:
@@ -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)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user