mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-20 15:31:15 -05:00
more debugging messages
This commit is contained in:
@@ -81,8 +81,10 @@ class AwsSnsClient(SmsClient):
|
|||||||
PhoneNumber=to, Message=content, MessageAttributes=attributes
|
PhoneNumber=to, Message=content, MessageAttributes=attributes
|
||||||
)
|
)
|
||||||
except botocore.exceptions.ClientError as e:
|
except botocore.exceptions.ClientError as e:
|
||||||
|
self.current_app.logger.error(e)
|
||||||
raise str(e)
|
raise str(e)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
|
self.current_app.logger(e)
|
||||||
raise str(e)
|
raise str(e)
|
||||||
finally:
|
finally:
|
||||||
elapsed_time = monotonic() - start_time
|
elapsed_time = monotonic() - start_time
|
||||||
|
|||||||
@@ -99,8 +99,11 @@ def send_sms_to_provider(notification):
|
|||||||
"international": notification.international,
|
"international": notification.international,
|
||||||
}
|
}
|
||||||
db.session.close() # no commit needed as no changes to objects have been made above
|
db.session.close() # no commit needed as no changes to objects have been made above
|
||||||
|
current_app.logger.info("sending to sms")
|
||||||
message_id = provider.send_sms(**send_sms_kwargs)
|
message_id = provider.send_sms(**send_sms_kwargs)
|
||||||
|
current_app.logger.info(f"got message_id {message_id}")
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
|
current_app.logger.error(e)
|
||||||
notification.billable_units = template.fragment_count
|
notification.billable_units = template.fragment_count
|
||||||
dao_update_notification(notification)
|
dao_update_notification(notification)
|
||||||
raise e
|
raise e
|
||||||
|
|||||||
Reference in New Issue
Block a user