Paper Dynasty Database - PostgreSQL database service
The card render endpoint's file-on-disk cache short-circuit returned FileResponse immediately when the cached PNG existed, bypassing the backfill BackgroundTask that populates battingcard.image_url / pitchingcard.image_url. If a variant row was later recreated with image_url=NULL while the PNG was still cached, the DB column stayed NULL forever, breaking every downstream consumer that reads image_url for display. Extract the backfill-scheduling logic into a _schedule_variant_image_backfill helper and call it on both the cache-hit and full-render paths. The helper's internal guards (variant > 0, tier is None, row exists with NULL image_url) keep the happy-path cache hit a no-op. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> |
||
|---|---|---|
| .gitea/workflows | ||
| .githooks | ||
| app | ||
| docs | ||
| migrations | ||
| scripts | ||
| storage/templates | ||
| tests | ||
| .dockerignore | ||
| .env | ||
| .env.example | ||
| .gitignore | ||
| CLAUDE.md | ||
| compose.production.yml | ||
| docker-compose.yml | ||
| Dockerfile | ||
| LICENSE | ||
| pyproject.toml | ||
| requirements.txt | ||
| ruff.toml | ||
| run-local.sh | ||
| VERSION | ||