The Draft on the real holding tank (2026-11-15, LOCAL ONLY): tankpool.js 'iap' mode = signed client for InstantAdPay's draft partner routes
TANK_MODE=iap (or hub) + IAP_URL + DRAFT_PARTNER_SECRET: pool / adopt / release / status as HMAC-signed POSTs ('draft.v1.' + ts +
newline + body, X-Draft-Ts / X-Draft-Sig). The stub stays the default and keeps every existing test. adopt carries the coach claim
(wallet, hubId, username, positions = store.positionsOf) and a request id; one retry with the same rid on a network failure, so a
retry never makes two adoptions. release sends why 'coach' | 'return' + the pick's iap ref and takes InstantAdPay's outcome
(returned / kept / done). league.sweep follows a pick InstantAdPay closed first (its own 3-day sweep, a release there, a LinkSpin
follow). Surfing arrives as ad credits (surfCredits, shown "N ad credits" to coaches, +10 scouting like surf POL); games stay
"not tracked yet" (InstantAdPay has no per-member game record).
Fix found by the cross test: a tank refusal about the COACH (no InstantAdPay account, full, not vested, hub off) used to mark the
person unavailable and let the same coach choose again, which would burn the whole pool; now the slot passes (skip 'tank: <code>')
and a silent tank pauses the draft (nothing recorded, the next tick retries the same slot). Manual picks record nothing on either.
Tests: unit 62/62 (2 new: skip + wait), smoke 156/156 (ports 3561-3564), qa/iap-tank.test.cjs 23/23 (this client + league against
InstantAdPay's REAL draftpartner.js + tank.js from the sibling checkout behind a signed server on 3565, then a dead port 3566).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -56,15 +56,29 @@ Deviation from the mockup on purpose: the mockup's coach card showed an email li
|
||||
```
|
||||
npm ci
|
||||
node server.js # prototype mode (files, stub tank); never launch this way
|
||||
node qa/unit.test.cjs # 60 checks: tiers, tank rules, earned order, the clocked draft, returns, boards, the split model
|
||||
node qa/unit.test.cjs # 62 checks: tiers, tank rules, earned order, the clocked draft, tank refusals, returns, boards, the split model
|
||||
# against the fork rehearsal (to the wei), Central weeks, the league end to end
|
||||
node qa/smoke.mjs # 156 checks against stand-in hub / chain / Telegram (ports 3561-3564) + Playwright 1280/390
|
||||
UI_FONTS=1 node qa/smoke.mjs # same, Google Fonts allowed so qa/out screenshots show the real type
|
||||
node qa/iap-tank.test.cjs # 23 checks: league + the real client against InstantAdPay's REAL draftpartner.js + tank.js (sibling
|
||||
# checkout) behind a signed local server on 3565, then a dead port (3566); skips without the sibling
|
||||
node tools/pages.mjs # regenerate public/*.html (one source of copy + legal facts)
|
||||
node tools/art.mjs # icon, OG, proof cards, kit, tier cards; --draftday <base> <monday> for a Draft Day PNG
|
||||
```
|
||||
|
||||
## The real holding tank (built 2026-11-15, local only)
|
||||
|
||||
`TANK_MODE=iap` (or `hub`) switches tankpool.js from the stub to InstantAdPay's signed partner routes (`IAP_URL`, shared
|
||||
`DRAFT_PARTNER_SECRET`, 32+ characters, the same value on both apps). InstantAdPay is the tank's home and the single source of the
|
||||
pool: its tank.waiting() is already the one network tank (LinkSpin and hub arrivals included, anyone adopted on LinkSpin left out),
|
||||
so LinkSpin needs no route of its own. Every pick is a real `tank.adopt()` there: the 2-adoption count, the 24-hour grace, rule 3,
|
||||
the normal "X is now your sponsor" email (the only mail), the sponsor change through sponsorfollow and the hub. InstantAdPay
|
||||
checks "holds a 5x position" from the coach claim this app signs (positions), a wallet linked there and someone on its contract in
|
||||
the coach's line. Picks keep their 3-day window there too; whichever sweep runs first, both apps end with the same outcome
|
||||
(returned / kept / done). A tank refusal about the coach passes the draft slot; a silent tank pauses the draft until the next tick.
|
||||
|
||||
|
||||
## Phase 2 (needs Marty's go): see the open questions in the build report
|
||||
|
||||
Hub `HUB_SITES` entry `fivex` + secret; `tankpool.js` hub mode (pool read, adopt through the tank, status); the network-sites list
|
||||
Hub `HUB_SITES` entry `fivex` + secret; `TANK_MODE=iap` + `DRAFT_PARTNER_SECRET` + `IAP_URL` (above); the network-sites list
|
||||
and LinkSpin `nw5x`; the contract on chain with the prize wallet; DOCSTORE_URL; old-member reconciliation; PolHunter mission.
|
||||
|
||||
Reference in New Issue
Block a user