Unified search returns titles only, never episodes #172

Closed
opened 2026-08-24 16:12:28 +01:00 by naps62-yolo · 0 comments
Owner

Implements the §9.2 change from #169: unified search returns titles only.

Depends on: #169

Searching the library for "rick and morty" currently returns 85 rows — the series
plus 84 episodes. #161 tried to narrow this by requiring a query token to match
the episode title, but the episodes that survive are season-0 specials named
Rick and Morty The Non-Canonical Adventures: The Thing and similar. Every token
of the query appears in their titles, so the filter passes and they all surface.

Rather than narrow the rule again, remove the row type. Unified search returns
series and movies, in library and on TMDB. Episodes never appear, under any query.
Season rows are not introduced.

Scope in crates/arr-api/src/search.rs:

  • Drop the episode branch of the library query.
  • Delete the token-matching machinery #161 added — the json_each EXISTS clause
    and the doubly-bound tokens parameter — along with anything left unused once
    the episode branch is gone. It is dead weight the moment episodes stop being
    returned, and leaving it invites a future session to wire it back up.
  • Remove episode from the response's row kinds, and from the OpenAPI schema.

The three #161 test cases that assert on episode rows are asserting the withdrawn
rule and should go with it. Replace them with one that pins the new behaviour: a
query matching an episode title and nothing else returns no rows for that series
beyond the series itself.

Check whether the SPA renders an episode row kind in unified search; if it does,
that rendering path goes too. Deep links to /episodes/{id}/releases are a
different feature and stay.

Implements the §9.2 change from #169: unified search returns titles only. Depends on: #169 Searching the library for "rick and morty" currently returns 85 rows — the series plus 84 episodes. #161 tried to narrow this by requiring a query token to match the episode title, but the episodes that survive are season-0 specials named `Rick and Morty The Non-Canonical Adventures: The Thing` and similar. Every token of the query appears in their titles, so the filter passes and they all surface. Rather than narrow the rule again, remove the row type. Unified search returns series and movies, in library and on TMDB. Episodes never appear, under any query. Season rows are not introduced. Scope in `crates/arr-api/src/search.rs`: - Drop the episode branch of the library query. - Delete the token-matching machinery #161 added — the `json_each` EXISTS clause and the doubly-bound `tokens` parameter — along with anything left unused once the episode branch is gone. It is dead weight the moment episodes stop being returned, and leaving it invites a future session to wire it back up. - Remove `episode` from the response's row kinds, and from the OpenAPI schema. The three #161 test cases that assert on episode rows are asserting the withdrawn rule and should go with it. Replace them with one that pins the new behaviour: a query matching an episode title and nothing else returns no rows for that series beyond the series itself. Check whether the SPA renders an episode row kind in unified search; if it does, that rendering path goes too. Deep links to `/episodes/{id}/releases` are a different feature and stay.
naps62-yolo added this to the Removal and navigation milestone 2026-08-24 16:12:28 +01:00
naps62-yolo added the phase/5-uidifficulty/easyarea/apitype/bug labels 2026-08-24 16:12:28 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Reference: yolo/arr#172