feat(workers): data-freshness monitor (Celery beat → GlitchTip) #1904

Merged
bot-backend merged 2 commits from feat/freshness-monitor into main 2026-06-25 11:29:35 +00:00

2 commits

Author SHA1 Message Date
f59d874bac chore(codegen): regen api-types after /freshness handler refactor
All checks were successful
CI / frontend-tests (pull_request) Successful in 1m10s
CI / openapi-codegen-check (pull_request) Successful in 2m10s
CI / changes (pull_request) Successful in 8s
CI / backend-tests (pull_request) Successful in 11m25s
The endpoint docstring (→ openapi description → api-types JSDoc) changed when
scrape_freshness was split into compute_freshness + thin handler, so the
committed api-types.ts was stale and openapi-codegen-check failed. Regenerated
via the CI chain (only JSDoc lines differ; no shape change). Refs #73
2026-06-25 16:17:23 +05:00
6d6abf30b1 feat(workers): Celery-beat data-freshness monitor with GlitchTip alerts
Some checks failed
CI / backend-tests (pull_request) Successful in 11m11s
CI / changes (pull_request) Successful in 7s
CI / frontend-tests (pull_request) Has been skipped
CI / openapi-codegen-check (pull_request) Failing after 2m3s
Extract compute_freshness(db) from the /admin/scrape/freshness handler (single
source of truth, endpoint response unchanged) and add a daily beat task
scrape_freshness_check that alerts via sentry_sdk.capture_message when a source
is stale/failed — level=error if a critical source fully failed, else warning;
also logs at matching severity so a no-DSN worker still surfaces it. Registered
in celery include + beat (09:00 MSK daily, after the nightly scraper cluster).

Closes #freshness-monitor (rank 7 follow-up)
2026-06-25 16:02:13 +05:00