Every source counts: one ladder holds every source's links, and watchsports.su joins (#128, #127) #129

Merged
cmoriarty merged 1 commit from feature/source-fallback into main 2026-11-08 21:15:52 -05:00
Owner

Milestone "Every source counts": #128 and #127.

TheTVapp's list was read every minute, but none of its links was ever tried. Every read the app made on its own used only a game's first source, which is Sportsurge.

  • The new key. resolution.ANY ("any") keys one ladder per game, holding every listed source's links. _EverySource gathers each source's candidates under that source's own host lock, and reads each link through the adapter of its own kind. The links are ordered as any ladder orders them: tier, then the host's record, then listed order between equals. A source that doesn't list the game adds nothing. The walk is "not listed" only when no source lists the game, so the #72 wait still holds. The ladder is read again when the game's sources change.
  • What moved from the first source to any:
    • the scheduler (prewarm.read_kind);
    • the Ready rule and the guide's quality label;
    • the readiness view, whose link and standby now name their source;
    • the feed's channel URL, now ?s=any;
    • the background channels, the followed games' watch keys, an unpinned channel's tune, and the filler card;
    • the resolve endpoint's default. Its source now names the source of the link that landed.
  • What follows from it. Recoveries, swaps and standby searches cross sources, and another source's stream counts as a different stream. A resolve that names a source still reads that source alone.
  • The readiness snapshot now carries "keys": "any" and each ladder's sources. A snapshot without the marker moves its entries and standbys to any, so the restart for this deploy keeps its Ready games.

#127: a women's college basketball source

A live survey of the two sites #127 names (docs/stream-sources.md, 2026-11-08/09):

  • watchsports.su, wired. It is a third source. Its pages are keyed on ESPN's event ids (/wcbb/<id>, /nba/<id>), so no name matching is needed, and none of its pages is gated. Its list is read on the hub's cadence. A game it lists with streams gains a watchsports reference after its other sources.
    • Links whose URL names another game are dropped. Its pages reuse links across games: the USC women's page carried two links to the USC men's game.
    • Its links are read through the player-page reader, which moves from sportsurge.py into resolver/player.py, so no adapter reaches into another.
    • The Admin page's Game lists row counts its rows.
  • What it gave that night. It listed 12 of ESPN's 68 women's games, 2 of them with streams, and none of its women's links verified (one plays only inside its own page's session). Its NBA links verified, 5 of 14, at up to 1280×720 59.94 fps.
  • streameast.cool, not wired. It carries thetvapp's streams: the same embed ids and the same playlists.
  • Women's games. The real gain is #128: thetvapp, which lists some women's games, is finally tried for them.
  • Also found, not changed here. The shared reader takes a JW Player analytics ping as the stream on DaddyLive pages, because is_m3u8 accepts .m3u8 anywhere in the query.

Checks

  • make test: 1220 passed, 1 skipped
  • npm --prefix frontend test: 249 passed
  • make e2e: every leg passed
  • openspec validate every-source-counts --strict: valid
  • Live, from this Mac, with the branch's code:
    • A women's game's every-source walk tried Sportsurge's link, then TheTVapp's, in one walk.
    • The new verifier verified 4 of 6 live TheTVapp games at 1280×720 30 fps. The old one verified 2 of 4.
    • The other two failed on a 404 for the newest segment. Every segment of both answered 200 moments later; the 404 sampling is in this PR.

🤖 Generated with Claude Code

Milestone "Every source counts": #128 and #127. ## #128: every source's links in one ladder TheTVapp's list was read every minute, but none of its links was ever tried. Every read the app made on its own used only a game's first source, which is Sportsurge. - **The new key.** `resolution.ANY` (`"any"`) keys one ladder per game, holding every listed source's links. `_EverySource` gathers each source's candidates under that source's own host lock, and reads each link through the adapter of its own kind. The links are ordered as any ladder orders them: tier, then the host's record, then listed order between equals. A source that doesn't list the game adds nothing. The walk is "not listed" only when no source lists the game, so the #72 wait still holds. The ladder is read again when the game's sources change. - **What moved from the first source to `any`:** - the scheduler (`prewarm.read_kind`); - the Ready rule and the guide's quality label; - the readiness view, whose link and standby now name their `source`; - the feed's channel URL, now `?s=any`; - the background channels, the followed games' watch keys, an unpinned channel's tune, and the filler card; - the resolve endpoint's default. Its `source` now names the source of the link that landed. - **What follows from it.** Recoveries, swaps and standby searches cross sources, and another source's stream counts as a different stream. A resolve that names a source still reads that source alone. - **The readiness snapshot** now carries `"keys": "any"` and each ladder's `sources`. A snapshot without the marker moves its entries and standbys to `any`, so the restart for this deploy keeps its Ready games. ## #127: a women's college basketball source A live survey of the two sites #127 names (docs/stream-sources.md, 2026-11-08/09): - **watchsports.su, wired.** It is a third source. Its pages are keyed on ESPN's event ids (`/wcbb/<id>`, `/nba/<id>`), so no name matching is needed, and none of its pages is gated. Its list is read on the hub's cadence. A game it lists with streams gains a `watchsports` reference after its other sources. - Links whose URL names another game are dropped. Its pages reuse links across games: the USC women's page carried two links to the USC men's game. - Its links are read through the player-page reader, which moves from `sportsurge.py` into `resolver/player.py`, so no adapter reaches into another. - The Admin page's Game lists row counts its rows. - **What it gave that night.** It listed 12 of ESPN's 68 women's games, 2 of them with streams, and none of its women's links verified (one plays only inside its own page's session). Its NBA links verified, 5 of 14, at up to 1280×720 59.94 fps. - **streameast.cool, not wired.** It carries thetvapp's streams: the same embed ids and the same playlists. - **Women's games.** The real gain is #128: thetvapp, which lists some women's games, is finally tried for them. - **Also found, not changed here.** The shared reader takes a JW Player analytics ping as the stream on DaddyLive pages, because `is_m3u8` accepts `.m3u8` anywhere in the query. ## Checks - `make test`: 1220 passed, 1 skipped - `npm --prefix frontend test`: 249 passed - `make e2e`: every leg passed - `openspec validate every-source-counts --strict`: valid - **Live, from this Mac, with the branch's code:** - A women's game's every-source walk tried Sportsurge's link, then TheTVapp's, in one walk. - The new verifier verified 4 of 6 live TheTVapp games at 1280×720 30 fps. The old one verified 2 of 4. - The other two failed on a 404 for the newest segment. Every segment of both answered 200 moments later; the 404 sampling is in this PR. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
#128: TheTVapp's list was read every minute, but its links were never
tried. Every read the app made on its own used a game's first source,
which is Sportsurge, and for a women's game Sportsurge answers "not
listed" at once.

- resolution.ANY ("any") keys an every-source ladder. _EverySource
  gathers every listed source's candidates under each source's own host
  lock, and reads each link through the adapter of its own kind. The
  ladder is read again when a game's sources change. A walk is not
  listed only when no source lists the game (the #72 wait).
- These moved from the first source to ANY: the scheduler
  (prewarm.read_kind), the Ready rule, the readiness view (whose link
  and standby name their source), the feed's ?s=any, the background
  channels, the watch keys, the unpinned tune, the filler card, and the
  resolve endpoint's default, whose "source" names the source of the
  link that landed. A named source still reads that source alone.
- verify: the sequence gets up to three polls, one target duration
  apart, and a 404 on the newest segment samples the one before it.
  TheTVapp's CDN lists two 4 s segments about every 9 s behind a 3 s
  cache, so half its working streams failed "did not advance".
- readiness_store: a "keys" marker and each ladder's sources. A
  snapshot from before moves to ANY, so the restart keeps its Ready
  games.

#127: watchsports.su is a third source. Its pages are keyed on ESPN's
event ids, ungated, and read on the hub's cadence. Its links are read
through the player-page reader, which moves into resolver/player.py so
no adapter reaches into another. Links that name another game are
dropped, and the Admin Game lists row counts its rows. streameast.cool
carries thetvapp's streams, so it is not wired. None of watchsports'
women's links verified on the survey night, but its NBA links did, at
1280x720 59.94 fps (docs/stream-sources.md, 2026-11-08/09).

Lanes: make test 1220 passed (1 skipped), frontend 249, make e2e
passed, openspec validate every-source-counts --strict valid.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign in to join this conversation.
No reviewers
No labels
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
cmoriarty/sports-breaker!129
No description provided.