diff --git a/workers/security_notification_worker.py b/workers/security_notification_worker.py index a33bc9762..a583a378c 100644 --- a/workers/security_notification_worker.py +++ b/workers/security_notification_worker.py @@ -39,8 +39,11 @@ class SecurityNotificationWorker(QueueWorker): if should_retry: raise JobException() else: - # Return to mark the job as "complete", as we'll never be able to finish it. + # Remove the job from the API. logger.error('Failed to handle security notification %s', notification_name) + secscan_api.mark_notification_read(notification_name) + + # Return to mark the job as "complete", as we'll never be able to finish it. return False self.extend_processing(_PROCESSING_SECONDS, json.dumps(data))