- 313 new markdown files created - 30 relationships embedded - 313 entries indexed - State initialized with usage data
2.0 KiB
2.0 KiB
| id | type | title | tags | importance | confidence | created | updated | relations | |||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| a918ab78-70dc-49bf-bcb8-e98e6bdd624e | solution | Paper Dynasty: Fixed card generation after PostgreSQL migration |
|
0.9 | 0.8 | 2026-02-02T01:39:08.756078+00:00 | 2026-02-02T01:39:08.756078+00:00 |
|
Problem: After migrating Paper Dynasty database from SQLite to PostgreSQL, card generation endpoints returned 'Internal Server Error' with jinja2.exceptions.TemplateNotFound for 'player_card.html'.
Root Cause: The storage/templates/ directory containing card rendering templates (player_card.html, topright_batter.html, topright_pitcher.html, etc.) was not included in the production deployment. The directory is gitignored and was lost during migration.
Solution:
- Recovered templates from old server:
scp pd-database:/home/cal/container-data/pd-database/storage/templates/*.html ../database/storage/templates/ - Updated .gitignore to allow templates: Add
!storage/templates/afterstorage/ - Force-added to git:
git add -f storage/templates/ - For immediate fix, SCP'd directly to production:
scp -r ../database/storage/templates/ akamai:/root/container-data/paper-dynasty/storage/ - Restarted API:
ssh akamai 'cd /root/container-data/paper-dynasty && docker compose restart api'
Templates Required:
- player_card.html (main card template)
- topright_batter.html, topright_pitcher.html (position-specific headers)
- results_vl.html, results_vr.html (batting results vs L/R)
- result_columns.html, style.html (layout/styling)
Prevention: When deploying database container updates, verify storage/templates/ is mounted or included in image.
Related: PostgreSQL migration guide at /mnt/NV2/Development/paper-dynasty/database/docs/POSTGRES_MIGRATION_GUIDE.md