Spaces:
Runtime error
Runtime error
Commit History
-
fix(templates): consolidate Jinja2Templates instances to fix /club 500
club_routes, lobby_routes, and feedback_routes each created their own Jinja2Templates instance and did not register the clay_balance or agent_any_unread globals. base.html calls agent_any_unread() inside the show_player_agents block, which is True by default, so any route rendered by those routers threw a Jinja2 UndefinedError → HTTP 500. Introduces app/web/_templates.py as the single shared instance with all four globals registered. All routers import from it. Feature-flag tests now also reload _templates before reloading routes. Two lobby integration tests that were failing for the same root cause now pass (2 pre-existing failures remain, down from 4). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>ecf7744
-
docs(gotchas): note HF full rebuild on every push + API sha check tip
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>fda2c82 -
docs: add ARCHITECTURE.md + GOTCHAS.md, rewrite README for Lucas handover
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>1d3a309
-
Phase 4.0–4.3: demo prep — auth, Elo fairness, rooms, lobbies, conversational entry, evolution
Big stretch of demo-prep work, shipped across seven sub-phases under a "zero-button, immersive" design direction that emerged mid-stretch. Phase 4.0 — foundations * 4.0a email+username+password login (Argon2, signup/login/forgot/reset, per-user settings, legacy-player compat). Migration 0007. * 4.0b opponent-ACPL-weighted Elo gain + consecutive-easy-wins soft cap + `matches.is_private` flag that zeroes Elo (anti-farm guardrail). Migration 0008. * 4.0c MockEngine was shuffling knights/bishops in the opening due to a naive alphabetical-first UCI pick — now filters direct reversals of recent own moves + 3-fold inducing moves. Phase 4.1 — character rooms Each grandmaster gets a themed room (palette CSS-var overrides, ambient audio track, backdrop image, emotion-clip mapping). `app/characters/rooms.py` + base.html/body[data-theme]/inline-style pipe. Ambient-audio JS with mute toggle + localStorage persistence. Viktor emoti…7bad702
-
Phase 3c (D): frontend polish pass — Metropolis design system
Aesthetic direction: a discreet old-world chess café crossed with a precise digital instrument — brass, ink, felt, parchment, under warm light. Dark theme with warm undertones, not cool neutrals. Design system (base.html): - Color tokens as CSS custom properties (--mp-bg, --mp-surface-1..3, --mp-hairline/-2, --mp-ink/muted/faint/ghost, --mp-brass/bright/dim, --mp-felt/bright, --mp-oxblood, --mp-ink-blue(-alt), --mp-rating-*) - Typography: Fraunces (display serif w/ optical sizing + SOFT/WONK axes), IBM Plex Sans (body), IBM Plex Mono (numerics / eyebrows) - Utilities: .mp-display, .mp-italic, .mp-mono, .mp-eyebrow, .mp-hr, .mp-brass-rule - Components: .mp-panel/.mp-panel-raised/.mp-framed (brass corner marks), .mp-btn (brass/ghost/danger variants), .mp-chip, .mp-input, .mp-board-frame, .conn-pill (live/retry/lost), .mp-livedot (breathing pulse) - Motion: single choreographed .mp-enter + stagger slots (1/2/3), custom --mp-ease cubic-bezier. No ambient animation. Shared Jin…ac4b86d -
Phase 3b: Socket.IO real-time gameplay, streamed post-match, disconnect handling
- python-socketio AsyncServer on /play namespace, mounted alongside FastAPI - Event contract modelled with Pydantic (app/sockets/events.py) - Streamed turn loop runs engine + Subconscious concurrently so memory_surfaced lands before agent_move (app/matches/streaming.py) - Pending player chat buffered into Match.extra_state and drained on next Subconscious call; FIFO caps + per-socket rate limit with feedback event - Disconnect cooldown registry (app/sockets/disconnect.py) arms on socket drop, cancels on reconnect, abandons on timeout and kicks off post-match - Post-match processor gains status_callback hook; socket bridge dispatches via asyncio.run_coroutine_threadsafe against the startup-captured loop - REST gameplay kept as fallback, returns X-Deprecated header - play.html rewritten on Socket.IO client: connection pill, always-on chat, thinking eta, memory ribbon, disconnect overlay + countdown, streamed post-match panel → auto-redirect to summary - Single-worker assumpti…c2d8a75