Episodes are never grouped by version, so the resolver that does it is unreachable #215

Closed
opened 2026-09-12 19:07:19 +02:00 by Claude · 1 comment
Collaborator

ListCollection::TvShows is passed nowhere. crates/ephyra-app/src/scan/tree/shows.rs never calls resolve_list, so episodes_grouped_by_version (crates/ephyra-naming/src/video/list.rs:193) is dead against the app — the code is ported, tested in ephyra-naming, and unreachable from a scan.

Upstream runs GetEpisodesGroupedByVersion for CollectionType.tvshows, so two files of one episode (S01E01.mkv and S01E01 - 1080p.mkv) are one row with an alternate version upstream, and two episode rows here.

Reach

The naming half exists and passes its own corpus; what is missing is the caller. movies.rs shows the shape — it calls resolve_list with a Collection and reads the group back — so this is wiring an existing resolver into the series walk rather than porting anything new.

Note the row this would produce is an alternate version, so it lands on the same missing join as the films do.

Verifying

cargo xtask reference gen-library-kinds registers no tvshows library today; the mixed tree added for #208 has a series in it. Either gains two files of one episode cheaply.

Found reviewing #207.

`ListCollection::TvShows` is passed nowhere. `crates/ephyra-app/src/scan/tree/shows.rs` never calls `resolve_list`, so `episodes_grouped_by_version` (`crates/ephyra-naming/src/video/list.rs:193`) is dead against the app — the code is ported, tested in `ephyra-naming`, and unreachable from a scan. Upstream runs `GetEpisodesGroupedByVersion` for `CollectionType.tvshows`, so two files of one episode (`S01E01.mkv` and `S01E01 - 1080p.mkv`) are one row with an alternate version upstream, and two episode rows here. ## Reach The naming half exists and passes its own corpus; what is missing is the caller. `movies.rs` shows the shape — it calls `resolve_list` with a `Collection` and reads the group back — so this is wiring an existing resolver into the series walk rather than porting anything new. Note the row this would produce is an alternate version, so it lands on the same missing join as the films do. ## Verifying `cargo xtask reference gen-library-kinds` registers no `tvshows` library today; the `mixed` tree added for #208 has a series in it. Either gains two files of one episode cheaply. Found reviewing #207.
Author
Collaborator

Fixed in fe6b37c8, landed on main at 53ac9c6c.

A season's files are read through resolve_list with ListCollection::TvShows, so episodes_grouped_by_version is reachable from a scan. The answer key settles which file wins: of Show S02E01.mkv and Show S02E01 - 1080p.mkv, upstream makes the one naming a resolution the primary and owns the plain one under it, with PrimaryVersionId set and the presentation key shared. Ours now files the same, and the join #214 added serves them as one title with two sources.

Two things the key settled along the way:

  • An extra does count towards the mixed-folder flag. tests/scan.rs::an_extra_beside_an_episode_is_not_an_episode asserted the opposite on a guess and is corrected.
  • Upstream files an owned Trailer row beside the episode, which joined the list of extras this port does not resolve.

Not covered by the key: stacked episodes now produce part rows, and no case exercises them.

Fixed in `fe6b37c8`, landed on `main` at `53ac9c6c`. A season's files are read through `resolve_list` with `ListCollection::TvShows`, so `episodes_grouped_by_version` is reachable from a scan. The answer key settles which file wins: of `Show S02E01.mkv` and `Show S02E01 - 1080p.mkv`, upstream makes the one naming a resolution the primary and owns the plain one under it, with `PrimaryVersionId` set and the presentation key shared. Ours now files the same, and the join #214 added serves them as one title with two sources. Two things the key settled along the way: - An extra **does** count towards the mixed-folder flag. `tests/scan.rs::an_extra_beside_an_episode_is_not_an_episode` asserted the opposite on a guess and is corrected. - Upstream files an owned `Trailer` row beside the episode, which joined the list of extras this port does not resolve. Not covered by the key: stacked episodes now produce part rows, and no case exercises them.
Sign in to join this conversation.
No description provided.