Validation: Fix Alembic multiple heads -- migration branch conflict
Verdict: PASS
Ticket
forgejo_admin/basketball-api#337 — Fix Alembic multiple heads migration branch conflict. PR #338 resolved by renumbering conflicting migrations (031 to 032/033) and linearizing the chain through the hash-named migration
e09c9e678004.Board item: #819 on board-westside-basketball
Environment
Production k3s cluster,
basketball-api namespace. Pod: basketball-api-5ddc9f8695-s8g2m. Image: harbor.tail5b443a.ts.net/basketball-api/api:bbe2de042299cceadef1abc21dce4569ca1df8dc.Tiers Executed
Tier 1 (local) + Tier 3 (prod). No staging environment for this repo.
Checks
| # | Criterion | How Verified | Result | Evidence |
|---|---|---|---|---|
| 1 | <code>alembic heads</code> returns exactly 1 head | Tier 1: Cloned main from Forgejo, parsed all 35 migration files revision/down_revision chain | PASS | Single head at revision <code>035</code> (035_set_player_contract_overrides.py). Chain linearized: 005 to e09c9e678004 to 007 to ... to 035. |
| 2 | <code>alembic upgrade head</code> succeeds | Tier 3: Pod startup logs show Alembic ran successfully | PASS | <code>INFO [alembic.runtime.migration] Context impl PostgresqlImpl.</code> / <code>Will assume transactional DDL.</code> -- no errors, Uvicorn started immediately after. |
| 3 | Pod starts without CrashLoopBackOff | Tier 3: <code>kubectl get pods -n basketball-api</code> | PASS | Pod <code>basketball-api-5ddc9f8695-s8g2m</code> -- Status: Running, Ready: 1/1, Restarts: 0. |
| 4 | Woodpecker pipeline green for merge commit | Tier 3: Woodpecker pipeline #344 | PASS | Pipeline #344 (push to main) -- status: success. |
| 5 | Health endpoint responds 200 | Tier 3: <code>curl /healthz</code> | PASS | HTTP 200, body: <code>{"status":"ok"}</code> |
Regression Check
/docs-- HTTP 200 (Blackbox Exporter also confirms every 30s in pod logs)/public/schedule-- HTTP 200/healthz-- HTTP 200, continuous kube-probe checks every 10s with zero failures in logs/metrics-- HTTP 200 (Prometheus scraping every 30s)- Keycloak JWKS fetch successful (visible in pod logs: Fetched JWKS 2 keys)
- No error-level log entries in pod logs since startup
Discovered Issues
None.