docker-compose.yml contains hardcoded credentials (BOT_TOKEN, API_TOKEN,
RESTART_WEBHOOK_URL) and should never be committed. The *compose.yml gitignore
rule already excluded it but docker-compose.example.yml was not provided as a
reference for contributors.
- Add !docker-compose.example.yml negation to .gitignore so example is tracked
- Add docker-compose.example.yml with placeholder values for all secrets
Closes paper-dynasty-database#9
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Document all required environment variables for running the Discord bot,
including bot token, API credentials, database config, and webhook URL.
References paper-dynasty-database#9
Port the Check-In Player pack fix from the hotfix branch to the legacy
economy.py cog (which production currently loads instead of economy_new).
- Filter auto-open pack types from the manual open-packs menu
- Add pretty_name fallback for hyphenated pack type names
- Add ruff noqa for pre-existing star import warnings
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Check-In Player packs (auto-opened by daily check-in) could end up orphaned
in inventory if roll_for_cards failed. The open-packs command crashed because:
1. The hyphenated pack type name bypassed the pretty_name logic, producing an
empty select menu that Discord rejected (400 Bad Request)
2. Even if displayed, selecting it would raise KeyError in the callback since
"Check-In Player".split("-") doesn't match any known pack type token
Fixes:
- Filter auto-open pack types out of the manual open-packs menu
- Add fallback for hyphenated pack type names in pretty_name logic
- Replace KeyError with graceful user-facing message for unknown pack types
- Change "contact an admin" to "contact Cal" in all user-facing messages
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Tier labels as suffix tags: **Name** — Base Chrome [T1] (T0 gets no suffix)
- Compact progress line: bar value/threshold (pct) — removed formula and tier arrow
- Fully evolved shows `MAX` instead of FULLY EVOLVED
- Deleted unused FORMULA_LABELS dict
- Added _FULL_BAR constant, moved T0-branch lookups into else
- Fixed mock API shape in test (cards → items)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Unicode symbols (○ ◈ ◆ ✦ ★) were too similar to distinguish at a glance.
Now uses T1/T2/T3/T4★ prefixes with no prefix for base cards (T0).
Summary header reads "Base: 1 T1: 9 — 64 total" instead of cryptic symbols.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
When filters are active and return 0 results, show which filters were
applied and suggest removing them, instead of the misleading
"No refractor data found for your team."
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- RefractorPaginationView with ◀ Prev / Next ▶ buttons
- Buttons re-fetch from API on each page change
- Prev disabled on page 1, Next disabled on last page
- Only the command invoker can use the buttons
- Buttons auto-disable after 2 min timeout
- Single-page results show no buttons
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace freeform text inputs with dropdown selections:
- card_type: Batter, Starting Pitcher, Relief Pitcher
- tier: T0-T4 with names (Base Card through Superfractor)
- progress: "Close to next tier" option
- Removed season param (not useful for current UX)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Cast current_value and next_threshold to int to avoid ugly floating
point numbers like 53.0/149.0 in the progress display.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Log API error detail when refractor endpoint returns an error
- Show "Something went wrong" instead of misleading "No refractor data"
- Log empty response case for debugging
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Switch from client-side pagination (fetch all, slice) to server-side
(pass limit/offset/progress params to API)
- Fixes limit=500 rejection (API max is 100)
- Footer now shows total_count from API response
- progress=close filter delegated to API instead of client-side
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- data.get("cards") → data.get("items") to match list endpoint response
- formula_value → current_value (API field name)
- card_type from top-level → track.card_type (nested in track object)
- Add limit=500 param so API returns all cards instead of default 10
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Mark CRITICAL missing endpoint gap as resolved (database PR #173 merged)
- Add REF-API-06 through REF-API-10 covering the new GET /refractor/cards
list endpoint (team filter, card_type, tier, progress, pagination)
- Update prerequisites, execution checklist, and time estimates
- Total test cases: 87 (was 82)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Sections 7-8 (game simulation, tier-up notifications) are marked as
manual testing by Cal — impractical to automate via Playwright.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
82-case in-app test plan for Playwright automation covering /refractor status,
tier badges, post-game hooks, tier-up notifications, and edge cases.
Preflight script for quick deploy verification via curl.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace the logging-only stub in logic_gameplay.py with the real
notify_tier_completion from helpers/refractor_notifs.py. Tier-up
events now send Discord embeds instead of just logging.
- Import notify_tier_completion from helpers.refractor_notifs
- Remove 16-line stub function and redundant inline logging
- Update tests: verify real embed-sending behavior, replace
bug-documenting T1-5 diagnostic with shape validation guards
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Mock routing in _patch_db_get and _failing_db_get still checked for
"evolution/cards/" after the production endpoint was renamed, causing
all badge-presence assertions to pass vacuously (evo_state=None).
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Replaces type=registry cache (which causes 400 errors from Docker Hub
due to stale buildx builders) with type=local backed by a named Docker
volume on the runner. Adds cache rotation step to prevent unbounded growth.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Allows deploying to dev environment by pushing a "dev" tag.
Dev tags build with :dev Docker tag instead of :production.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Change `evolution/evaluate-game/` API call to `refractor/evaluate-game/` in
complete_game() hook (was calling the wrong endpoint path)
- Update all test assertions in test_complete_game_hook.py to match the
corrected endpoint path and update docstrings to "refractor" naming
- Remove helpers/evolution_notifs.py and tests/test_evolution_notifications.py
from this PR — they belong to PR #112 (WP-14 tier notifications). The
notify_tier_completion stub in logic_gameplay.py remains as the WP-14
integration target.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>