fix: include ck_prices_cache.json in similarity cache build and download flows

This commit is contained in:
matt 2026-04-04 20:25:33 -07:00
parent e03f22a697
commit 6ecd45117f
9 changed files with 21 additions and 4 deletions

View file

@ -13,7 +13,7 @@
# HOST=0.0.0.0 # Uvicorn bind host (only when APP_MODE=web).
# PORT=8080 # Uvicorn port.
# WORKERS=1 # Uvicorn worker count.
APP_VERSION=v4.6.1 # Matches dockerhub compose.
APP_VERSION=v4.6.2 # Matches dockerhub compose.
############################
# Theming

View file

@ -280,6 +280,7 @@ jobs:
- `card_files/processed/commander_cards.parquet` - Commander-only cache (fast lookups)
- `card_files/processed/.tagging_complete.json` - Tagging status
- `card_files/prices_cache.json` - Scryfall price cache
- `card_files/ck_prices_cache.json` - Card Kingdom price cache
- `card_files/prices_cache.json.ts` - Per-card price timestamps (if present)
EOF
@ -293,6 +294,7 @@ jobs:
git add -f card_files/processed/commander_cards.parquet
git add -f card_files/processed/.tagging_complete.json
git add -f card_files/prices_cache.json
git add -f card_files/ck_prices_cache.json 2>/dev/null || true
git add -f card_files/prices_cache.json.ts 2>/dev/null || true
git add -f README-cache.md

View file

@ -20,6 +20,11 @@ _No unreleased changes yet_
### Removed
_No unreleased changes yet_
## [4.6.2] - 2026-04-04
### Fixed
- **CK prices missing after GitHub cache download**: `ck_prices_cache.json` was not included in the files committed to `similarity-cache-data` by the build workflow, nor fetched by the `Download from GitHub` button or the orchestrator auto-download flow. All three paths now include the file (graceful 404 handling preserves backward compatibility with existing cache branches).
- **`commander_cards.parquet` missing from orchestrator download**: The orchestrator's auto-download list was missing `commander_cards.parquet`, which the route handler already included. Both lists are now consistent.
## [4.6.1] - 2026-04-04
### Added
- **Card Kingdom prices**: All price displays now show both TCGPlayer (TCG) and Card Kingdom (CK) prices side by side

View file

@ -138,6 +138,8 @@ async def download_github():
("card_files/processed/.tagging_complete.json", "card_files/processed/.tagging_complete.json"),
("card_files/similarity_cache.parquet", "card_files/similarity_cache.parquet"),
("card_files/similarity_cache_metadata.json", "card_files/similarity_cache_metadata.json"),
("card_files/prices_cache.json", "card_files/prices_cache.json"),
("card_files/ck_prices_cache.json", "card_files/ck_prices_cache.json"),
]
downloaded = []

View file

@ -1377,9 +1377,12 @@ def _ensure_setup_ready(out, force: bool = False) -> None:
base_url = "https://raw.githubusercontent.com/mwisnowski/mtg_python_deckbuilder/similarity-cache-data"
files_to_download = [
("card_files/processed/all_cards.parquet", "card_files/processed/all_cards.parquet"),
("card_files/processed/commander_cards.parquet", "card_files/processed/commander_cards.parquet"),
("card_files/processed/.tagging_complete.json", "card_files/processed/.tagging_complete.json"),
("card_files/similarity_cache.parquet", "card_files/similarity_cache.parquet"),
("card_files/similarity_cache_metadata.json", "card_files/similarity_cache_metadata.json"),
("card_files/prices_cache.json", "card_files/prices_cache.json"),
("card_files/ck_prices_cache.json", "card_files/ck_prices_cache.json"),
]
download_success = True

View file

@ -144,7 +144,7 @@ services:
# WEB_THEME_FILTER_PREWARM: "0"
WEB_AUTO_ENFORCE: "0" # 1=auto-run compliance export after builds
WEB_CUSTOM_EXPORT_BASE: "" # Optional: custom base dir for deck export artifacts
APP_VERSION: "v4.6.1" # Displayed version label (set per release/tag)
APP_VERSION: "v4.6.2" # Displayed version label (set per release/tag)
# ------------------------------------------------------------------
# Misc / Land Selection (Step 7) Environment Tuning

View file

@ -146,7 +146,7 @@ services:
# WEB_THEME_FILTER_PREWARM: "0"
WEB_AUTO_ENFORCE: "0" # 1=auto-run compliance export after builds
WEB_CUSTOM_EXPORT_BASE: "" # Optional: custom base dir for deck export artifacts
APP_VERSION: "v4.6.1" # Displayed version label (set per release/tag)
APP_VERSION: "v4.6.2" # Displayed version label (set per release/tag)
# ------------------------------------------------------------------
# Misc / Land Selection (Step 7) Environment Tuning

5
docs/releases/v4.6.2.md Normal file
View file

@ -0,0 +1,5 @@
# MTG Python Deckbuilder v4.6.2
## Fixed
- **CK prices missing after GitHub cache download**: `ck_prices_cache.json` was not committed to the `similarity-cache-data` branch by the build workflow, and was not fetched by the "Download from GitHub" button or the orchestrator auto-download. All three paths now include it (graceful 404 fallback preserves backward compatibility).
- **`commander_cards.parquet` missing from orchestrator download**: The orchestrator's download list was missing this file, creating an inconsistency with the route handler. Both lists are now in sync.

View file

@ -5,7 +5,7 @@ build-backend = "setuptools.build_meta"
[project]
name = "mtg-deckbuilder"
version = "4.6.1"
version = "4.6.2"
description = "A command-line tool for building and analyzing Magic: The Gathering decks"
readme = "README.md"
license = {file = "LICENSE"}