harvard-lil / perma

Indelible links
411 stars 70 forks source link

Tweak logging #3423

Closed rebeccacremona closed 8 months ago

rebeccacremona commented 8 months ago

This is a very small PR to tweak our logging of captures made with the Scoop API.

1) We now store the Scoop job id in a dedicated database field, so that it is available even if the job never advanced beyond this loop (one variety of error we have been debugging).

2) We log the Scoop job id and status while in the loop, to make it easier to match up Perma logs and Scoop API logs, when something goes wrong.

matteocargnelutti commented 8 months ago

🏄 !

codecov[bot] commented 8 months ago

Codecov Report

Attention: 4 lines in your changes are missing coverage. Please review.

Comparison is base (d8def7c) 68.79% compared to head (97269b6) 68.78%. Report is 3 commits behind head on develop.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## develop #3423 +/- ## =========================================== - Coverage 68.79% 68.78% -0.02% =========================================== Files 53 53 Lines 7317 7316 -1 =========================================== - Hits 5034 5032 -2 - Misses 2283 2284 +1 ``` | [Files](https://app.codecov.io/gh/harvard-lil/perma/pull/3423?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=harvard-lil) | Coverage Δ | | |---|---|---| | [perma\_web/perma/models.py](https://app.codecov.io/gh/harvard-lil/perma/pull/3423?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=harvard-lil#diff-cGVybWFfd2ViL3Blcm1hL21vZGVscy5weQ==) | `86.35% <100.00%> (+0.01%)` | :arrow_up: | | [perma\_web/perma/admin.py](https://app.codecov.io/gh/harvard-lil/perma/pull/3423?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=harvard-lil#diff-cGVybWFfd2ViL3Blcm1hL2FkbWluLnB5) | `84.08% <0.00%> (+0.07%)` | :arrow_up: | | [perma\_web/perma/celery\_tasks.py](https://app.codecov.io/gh/harvard-lil/perma/pull/3423?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=harvard-lil#diff-cGVybWFfd2ViL3Blcm1hL2NlbGVyeV90YXNrcy5weQ==) | `47.13% <0.00%> (-0.08%)` | :arrow_down: |

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.