My job feed broke silently for 3 days. So I built a CI guardrail that fails the build when it happens again
说明与用途
jobfeed-watchdog 脚本在 CI 中自动检查 JSON 结构,并在回归时失败构建,提供即时警报以防止无声故障。
问题
A job feed returned an empty data field for three days without any alerts, causing dashboards to show zero jobs while the API was technically up.
结果
The CI guardrail automatically fails builds when a JSON feed’s structure regresses, providing immediate alerts and detailed diffs, preventing silent data loss.
工作流
- Install jobfeed-watchdog via pip or add the GitHub Action to .github/workflows
- Define feeds.json with endpoint URLs
- Configure the Action with feeds.json and min_records threshold
- Schedule the Action to run periodically
- On each run, the Action fingerprints the feed structure and compares it to the last known‑good state
- If a regression is detected, the Action fails the build and logs the specific signal that broke
证据
My job feed broke silently for three days before anyone noticed. The board's API hadn't gone down — it had just started returning an empty data field where there used to be a list.
jobfeed-watchdog runs a structural fingerprint on a scheduled basis against any JSON/YAML endpoint that returns a list of records... turns the Actions run red when something regresses.
The whole thing is 26 tests, all passing, stdlib-only: $ python -m pytest .............. 26 passed in 0.36s
- 记录日期: 2026-10-05T18:55:58.336Z