Skip to content

fix(health): register /healthz liveness probe route (#870)#889

Draft
vivekchand wants to merge 1 commit intomainfrom
bot-fix/issue-870-healthz-route-returns-404
Draft

fix(health): register /healthz liveness probe route (#870)#889
vivekchand wants to merge 1 commit intomainfrom
bot-fix/issue-870-healthz-route-returns-404

Conversation

@vivekchand
Copy link
Copy Markdown
Owner

Summary

GET /healthz was returning 404 because the route was never registered in bp_health. Cloud Run (and Kubernetes) use this path as a liveness probe, so a missing route means the health check silently fails. This PR adds a minimal, non-blocking handler that returns {"status": "ok", "version": "..."}.

Changes

  • routes/health.py: add GET /healthz handler at the end of bp_health; update module docstring route count from 11 → 12

Test plan

  • python3 -c 'import ast; ast.parse(open("routes/health.py").read())' — syntax clean
  • Start the server locally (make dev) and run curl -si http://localhost:8900/healthz — expect HTTP/1.1 200 OK with {"status":"ok","version":"..."}
  • Confirm existing /api/health endpoint still returns its full JSON payload unaffected

Bot meta

Draft PR opened autonomously based on the plan in #870. Marked draft for human review — mark Ready for Review once happy.

Closes #870


Generated by Claude Code

Cloud Run and Kubernetes send GET /healthz for health checks, but the
route was never registered in bp_health, causing a 404. Add a minimal
handler that returns {"status":"ok","version":"<ver>"} so the probe
passes without any blocking I/O.

Closes #870

Co-Authored-By: ClawMetry Autofix Bot <bot-autofix@clawmetry.dev>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[regression] GET /healthz -- FAIL_STATUS got 404 expected 200

1 participant