mirror of
https://github.com/nomadkaraoke/karaoke-gen.git
synced 2026-11-20 13:07:57 +09:00
Follow-up to the incident-hardening initiative — fixes the false "Post-deploy canary FAILED (v0.222.3)" page from the #987 deploy. **Root cause:** the R1 version-change gate did a single un-retried curl to the raw Cloud Run **origin** `/api/health/detailed`, which came back empty (cold start on the scaled-to-zero prior revision and/or origin edge-auth on the detailed endpoint). It logged `Currently-serving version: <unknown>` and **fail-opened → ran the canary on a no-bump deploy**, which then flake-failed on a review-page timing wait and paged. **Fixes:** 1. **Reliable gate** — read the currently-serving version via the **edge** (`https://api.nomadkaraoke.com/api/health/detailed`, warm + Cloudflare-fronted, verified to return the version) with retries. A no-bump deploy now correctly **skips** the canary. 2. **Retry the canary** — `--retries=2` so a single flaky UI wait doesn't page; only a failure surviving retries is real. (The happy-path's review-page waits are inherently flaky; the identical spec passed on the 0.223.2 deploy.) No app code changed → no version bump. YAML validated. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>