flake8 fixes

a stricter flake8 bump. mostly things around f strings and format
strings, but a couple of bad placeholder names in loops
This commit is contained in:
Leo Hemsted
2020-12-07 15:15:50 +00:00
parent d6555d887c
commit 9502f17d84
8 changed files with 23 additions and 21 deletions

View File

@@ -339,7 +339,7 @@ def save_api_email_or_sms(self, encrypted_notification):
try:
self.retry(queue=QueueNames.RETRY)
except self.MaxRetriesExceededError:
current_app.logger.error('Max retry failed' + f"Failed to persist notification {notification['id']}")
current_app.logger.error(f"Max retry failed Failed to persist notification {notification['id']}")
@notify_celery.task(bind=True, name="save-letter", max_retries=5, default_retry_delay=300)
@@ -604,7 +604,7 @@ def send_inbound_sms_to_service(self, inbound_sms_id, service_id):
self.retry(queue=QueueNames.RETRY)
except self.MaxRetriesExceededError:
current_app.logger.error(
f"Retry: send_inbound_sms_to_service has retried the max number of" +
"Retry: send_inbound_sms_to_service has retried the max number of" +
f"times for service: {service_id} and inbound_sms {inbound_sms_id}"
)
else: