Files
iptvnator/docs
4grayandClaude Opus 5 2ef0afbeca refactor(epg): shrink the two oversized files this PR grew, keep portal cards in scope
Two review follow-ups.

Greptile: the repo requires refactoring an already-oversized production file
before adding to it, and this PR had grown both files it touched. Extracted,
without behaviour change:

- `EpgProgramCache` — the 60 s "currently airing" memory, its in-flight
  request slots and the scope/offset cache keys.
- `EpgChannelMetadataLookup` — the icon/display-name lookup with the same
  playlist-first, Settings-fallback ladder.
- `DashboardLiveEpgPresenter` — the rails' XMLTV lookup and card enrichment,
  component-provided so the 30 s heartbeat dies with the page.

`epg.service.ts` 901 -> 727 and the rails component 1000 -> 842, both now
smaller than before this PR; the three new files are well under the 400-line
limit, and the generated max-lines baseline is unchanged.

Codex P2: the any-source retry now applies only to cards that carry a real
XMLTV key. An Xtream or Stalker card has none, so its lookup key is just its
display title, and searching every imported guide by title would let a
same-named M3U channel answer for a portal channel. Those cards keep the
strict scope — their own programmes come from the portal — and the flag is
part of the scope identity, so a guide-less M3U card and a portal card never
share an answer.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-20 20:27:32 +02:00
..