Skip to content

Commit

Permalink
Gather errors that don't produce logs; improve logging.
Browse files Browse the repository at this point in the history
  • Loading branch information
rebeccacremona committed Oct 27, 2023
1 parent 912d8ea commit 84c94a7
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions perma_web/perma/celery_tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -1067,6 +1067,9 @@ def capture_with_scoop(capture_job):
if poll_data['stderr_logs'] and didnt_load in poll_data['stderr_logs']:
logger.warning(f"{capture_job.link_id}: Scoop failed to load submitted URL ({capture_job.submitted_url}).")
capture_job.link.tags.add('scoop-load-failure')
elif not poll_data['stderr_logs'] and not poll_data['stdout_logs']:
logger.warning(f"{capture_job.link_id}: Scoop failed without logs ({poll_data['id_capture']}).")
capture_job.link.tags.add('scoop-silent-failure')
else:
logger.error(f"Scoop capture failed: {poll_data}")

Expand Down

0 comments on commit 84c94a7

Please sign in to comment.