Commit Graph

62 Commits

Author SHA1 Message Date
josh 47a8c34215 feat: game importance factor in hype scoring
CI / Lint (push) Failing after 6s
CI / Test (push) Has been skipped
CI / Build & Push (push) Has been skipped
Adds calculate_game_importance() that boosts Priority for high-stakes
regular-season matchups based on season progress (sharp ramp after game
55), playoff bubble proximity (wildcard rank ~17-19 = max relevance),
and divisional/conference rivalry (1.4x/1.2x multipliers). Max bonus
150 pts applied to both LIVE and PRE games; playoff and FINAL games
are unaffected. Extends standings schema with division, conference,
games_played, and wildcard_sequence fields fetched from the NHL API.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 18:39:55 -04:00
josh 8945b99782 feat: power play indicator with live countdown clock
CI / Lint (push) Successful in 5s
CI / Test (push) Successful in 5s
CI / Build & Push (push) Successful in 14s
Shows a red pill below the team rows when a PP is active, displaying
the team on the power play and a ticking countdown. PP clock always
resyncs from the API (no local anchoring) since 2-minute penalties
are short enough that accuracy matters throughout. Removed the old
inline PP text from team rows.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 14:58:31 -04:00
josh 257e2151c8 fix: smooth intermission clock by preserving local anchor across renders
CI / Lint (push) Successful in 5s
CI / Test (push) Successful in 6s
CI / Build & Push (push) Successful in 16s
Snapshot the locally-computed clock state before each re-render and
restore it afterwards, so the API response doesn't cause a visible
jump. Only resync to the API value in the final 60 seconds, where
accuracy matters.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 14:55:48 -04:00
josh 96529c4705 feat: smooth clock countdown for intermission and live play
CI / Lint (push) Successful in 6s
CI / Test (push) Successful in 6s
CI / Build & Push (push) Successful in 17s
Store seconds + received-at timestamp on time badge. A 1s interval
decrements locally so the clock never stutters between API polls.
Drift-corrected: always computed from the anchored API value, not
accumulated ticks. Re-render on each API response reanchors to the
real value.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 14:51:05 -04:00
josh e2d2c7dd97 feat: overhaul hype scoring algorithm
CI / Lint (push) Successful in 6s
CI / Test (push) Successful in 6s
CI / Build & Push (push) Successful in 15s
- Period base: playoff OT escalates indefinitely (P4=600, P5=750…),
  reg season P4=5-min OT (600), P5=shootout (700)
- Time priority range increased (max ~300 vs old ~120), calibrated
  to period length so 5-min reg season OT reads correctly
- Matchup multiplier inverted: higher period = less weight (any OT
  is exciting regardless of teams)
- Replace unconditional score_total with closeness bonus: rewards
  tight games regardless of goal volume (5-4 == 1-0 at same diff)
- Power play bonus: 30 (P1/P2) → 50/100/150 (P3 by time) → 200 (OT)
- Comeback bonus: one-time pulse (+50/75/100 by period) when trailing
  team scores to within 2 goals; keyed on team names, clears after
  firing, skips intermission

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 14:46:10 -04:00
josh 62afc1001e feat: amber top border for intermission games
CI / Lint (push) Successful in 7s
CI / Test (push) Successful in 6s
CI / Build & Push (push) Successful in 15s
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 14:10:02 -04:00
josh 3169d1a1ff fix: resolve 4 logic bugs found in code review
CI / Lint (push) Successful in 5s
CI / Test (push) Successful in 5s
CI / Build & Push (push) Successful in 17s
- utc_to_eastern: use zoneinfo instead of hardcoded EDT offset (-4)
  so start times are correct in both EST and EDT
- standings: fetch before truncate so a failed API call doesn't wipe
  existing standings data
- routes: call parse_games() once per request instead of three times
- scheduler: wrap run_pending() in try/except so an unhandled exception
  doesn't kill the background thread

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 14:06:45 -04:00
josh 56feb0a5f2 polish: improve game card aesthetics
CI / Lint (push) Successful in 19s
CI / Test (push) Successful in 8s
CI / Build & Push (push) Successful in 18s
- larger scores (1.6rem), logos (40px), and card width (290px)
- green top border accent on live game cards
- section headings reduced to small muted caps
- more breathing room in team rows
- slightly larger card radius and gap

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 14:00:18 -04:00
josh ed05d6adfc refactor: replace shots bar with inline SOG on team rows
CI / Lint (push) Successful in 5s
CI / Test (push) Successful in 6s
CI / Build & Push (push) Successful in 15s
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 13:57:00 -04:00
josh 889f429dc6 feat: move shots bar between team rows for cleaner layout
CI / Lint (push) Successful in 5s
CI / Test (push) Successful in 5s
CI / Build & Push (push) Successful in 14s
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 13:53:40 -04:00
josh 1394b21fb3 fix: use monochromatic near-white and slate gray for shots bar
CI / Lint (push) Successful in 5s
CI / Test (push) Successful in 5s
CI / Build & Push (push) Successful in 14s
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 13:49:52 -04:00
josh cb712245c2 fix: show shots bar during intermission
CI / Lint (push) Successful in 5s
CI / Test (push) Successful in 6s
CI / Build & Push (push) Successful in 14s
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 13:46:42 -04:00
josh 869a7a91b7 fix: use cyan and lime for shots bar
CI / Lint (push) Successful in 9s
CI / Test (push) Successful in 7s
CI / Build & Push (push) Successful in 13s
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 13:44:59 -04:00
josh 66fff68e6a fix: use sky blue and pink for shots bar to improve contrast
CI / Lint (push) Successful in 5s
CI / Test (push) Successful in 5s
CI / Build & Push (push) Successful in 11s
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 13:42:41 -04:00
josh bada8c0b7b fix: use perceptually balanced colors for shots bar
CI / Lint (push) Successful in 5s
CI / Test (push) Successful in 6s
CI / Build & Push (push) Successful in 13s
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 13:40:59 -04:00
josh 9ad563ed3f feat: add shots on goal bar to live game cards, clean up gitignore
CI / Lint (push) Successful in 5s
CI / Test (push) Successful in 5s
CI / Build & Push (push) Successful in 13s
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-29 13:19:59 -04:00
josh dd5ac945bd refactor: rename functions across codebase for clarity
CI / Lint (push) Successful in 7s
CI / Test (push) Successful in 5s
CI / Build & Push (push) Successful in 14s
2026-03-29 10:21:01 -04:00
josh a4dc7dff52 refactor: flatten app/scoreboard/ subpackage and rename files for clarity
CI / Lint (push) Successful in 5s
CI / Test (push) Successful in 6s
CI / Build & Push (push) Successful in 16s
2026-03-29 10:16:35 -04:00
josh da277e41a4 fix: center game boxes on page
CI / Lint (push) Successful in 4s
CI / Test (push) Successful in 5s
CI / Build & Push (push) Successful in 14s
2026-03-29 09:48:47 -04:00
josh d1d711828c fix: center and resize page title and section headings
CI / Lint (push) Successful in 5s
CI / Test (push) Successful in 5s
CI / Build & Push (push) Successful in 16s
2026-03-29 09:45:18 -04:00
josh 10d7cb9b02 refactor: rewrite UI with clean layout, fetch API, and proper card structure
CI / Lint (push) Successful in 4s
CI / Test (push) Successful in 5s
CI / Build & Push (push) Successful in 14s
2026-03-29 09:41:34 -04:00
josh 3994943757 good luck
CI / Lint (push) Successful in 58s
CI / Test (push) Successful in 8s
CI / Build & Push (push) Failing after 1m33s
2026-03-29 09:20:21 -04:00
goddard 8913b40a8c hotfix: correct for dst 2024-03-11 12:37:19 -04:00
goddard daabae1e49 fix: add shootout indicator 2024-02-25 01:17:04 -05:00
goddard a1352869ad fix: adjust game score calculation 2024-02-22 23:04:49 -05:00
goddard f059d4228b fix: raise gauge ceiling to 700 2024-02-22 23:04:38 -05:00
goddard 65369896cc fix: record sizes are now consistent 2024-02-22 02:16:12 -05:00
goddard 20ffd05df1 fix: correct date crossover time 2024-02-22 02:08:56 -05:00
goddard 5d65533ff5 fix: drop leading zero for scheduled games 2024-02-22 02:06:15 -05:00
goddard 960ff6e5ac fix: change date crossover to 3:00 am ETC 2024-02-22 02:00:39 -05:00
goddard 360188114e fix: adjust scoreboard time 2024-02-22 01:56:46 -05:00
goddard 94f9cced2e game priority: double differential adjustment at 5 minutes left in third 2024-02-22 01:17:13 -05:00
goddard 3edb84c333 fix: change scale to 650 instead of 600 2024-02-22 01:16:31 -05:00
goddard 6ec9a7aef1 fix: lower weight of total score 2024-02-22 00:14:39 -05:00
goddard dfb86f6fd5 changes hype meter scale to 600 instead of 700 2024-02-22 00:14:14 -05:00
goddard e5824cefc5 fix: sort games in intermission by time left 2024-02-22 00:11:22 -05:00
goddard 8c5de8602f feat: add matchup adjustment scaling. Earlier the period, the heavier we way the matchup strength 2024-02-21 23:52:06 -05:00
goddard 4da3c2dfdd fix: live game adjustments 2024-02-21 23:42:41 -05:00
goddard 07ff5ac055 feat: Push the games that are in intermission to the bottom, but retain their sort 2024-02-21 18:40:21 -05:00
goddard fe7449537b fix: minor header adjustments 2024-02-21 18:34:26 -05:00
goddard dd8d1ca12b fix: adjust pre and final state 2024-02-21 01:30:00 -05:00
goddard d285314a28 hotfix: define font size for more consistent look 2024-02-21 01:00:03 -05:00
goddard 53f0e69cc5 feature: adds hype meter to replace game score 2024-02-21 00:40:35 -05:00
goddard 4b6e8615b1 fix: weigh overtime heavier to compensate for time priority loss 2024-02-20 22:10:07 -05:00
goddard 31b4846287 fix: styles.css adjust live games 2024-02-20 22:09:45 -05:00
goddard a329c2e8b2 fix: styles.css adjustments 2024-02-20 14:32:17 -05:00
goddard 24de212b98 remove unnecessary comments 2024-02-20 01:35:24 -05:00
goddard 6abcd2e448 fix: change spacing between rows 2024-02-20 01:27:19 -05:00
goddard b3a09b27c0 fix: adjust game box spacing 2024-02-20 00:50:35 -05:00
goddard 8900bf0d14 fix: adjust sizing to fit space better 2024-02-20 00:47:29 -05:00