Skip to content

feat: Knockout Challenge recap + recipient export scripts - #138

Merged
dommango merged 2 commits into
mainfrom
feat/ko-recap-email-scripts
Jul 4, 2026
Merged

dommango merged 2 commits into
mainfrom
feat/ko-recap-email-scripts

Conversation

@dommango

@dommango dommango commented Jul 4, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • Adds scripts/r32-recap.ts — read-only script that prints real Round of 32 scorelines (flagging penalty-shootout matches) and the resolved Round of 16 matchups.
  • Adds scripts/export-challenge-recipients.ts — read-only script that pulls the opted-in Knockout Challenge entrant email list (mirrors the eligibility gate already used in lib/challenge/leaderboard.ts's getChallengeLeaderboard) to ko-list.csv.
  • Adds scripts/challenge-progress.ts — read-only script that pulls the public Knockout Challenge leaderboard and reports top standings, perfect-R32-bracket count, and average score.
  • ko-list.csv is gitignored — it carries real user emails (PII) and must never be committed.

Built to draft a one-off Knockout Challenge recap / Match Day Pickem promo email blast (sent as a Gmail draft, not part of this repo). The email leads with challenge standings (who's leading, average score) rather than raw match scores. All three scripts are reusable for the next round's recap (R16, QF, SF, Final).

Test plan

  • npm run typecheck passes
  • Ran all three scripts against production (read-only) and confirmed real output: 16 R32 results incl. 3 penalty shootouts, 8 resolved R16 matchups, 10 deduped recipient emails, 12-entrant leaderboard with a 4-way tie at the top
  • Confirmed none of the scripts contain any .update/.create/.delete Prisma calls

dommango-sys added 2 commits July 4, 2026 11:36
One-off tooling for the R32->R16 recap email blast: r32-recap.ts prints
real R32 scorelines (flagging penalty shootouts) plus resolved R16
matchups; export-challenge-recipients.ts pulls the opted-in Knockout
Challenge entrant email list (mirrors the eligibility gate in
lib/challenge/leaderboard.ts) to ko-list.csv, gitignored since it
carries real user emails.
scripts/challenge-progress.ts pulls the public Knockout Challenge
leaderboard (getChallengeLeaderboard) and reports top standings,
perfect-R32-bracket count, and average score — used for a
progress-focused recap email instead of raw match scorelines.
@dommango
dommango marked this pull request as ready for review July 4, 2026 21:22
@dommango
dommango merged commit 82b9db8 into main Jul 4, 2026
1 check passed
@dommango
dommango deleted the feat/ko-recap-email-scripts branch July 4, 2026 21:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant