Give the attention queue one liveness rule, in both readers #238

Closed
opened 2026-08-25 10:30:19 +01:00 by naps62-yolo · 1 comment
Owner

Two related gaps in the needs-a-decision queue, both found reviewing #226.

The season lane has no liveness filter. The daemon's episode lane filters
AND e.wanted = 1 AND e.state != 'available'
(crates/arr-daemon/src/attention.rs:260). The season lane #226 fixed has no
equivalent. So a season pack that hard-fails twice, falls back to per-episode
grabbing exactly as §6.2 says it should, and is then fully acquired keeps
notifying and keeps sitting in the queue for the full 30 days. §5.7 now
promises "a target the operator has dealt with stops producing failures and
drops out" — a season dealt with by the system working does not drop out.

The API and the daemon disagree about the same queue. The daemon filters
movies.wanted = 1 AND movies.state != 'available'
(attention.rs:133-141); the API's needs_decision
(crates/arr-api/src/movies.rs:785) has no such filter. Same for the episode
lane — daemon filters, API does not. GET /api/queues/attention therefore
lists titles that never produce an ntfy notification, which is the queue
telling the operator two different stories on two channels.

The divergence predates this milestone, but #226's new doc comment at
movies.rs:798-802 asserts "Both hard-fail branches hold to §5.7's bar", which
now overstates what the code does.

Scope: one liveness rule for all three lanes, applied in both readers, and
§5.7 amended to state it. Fix the doc comment or the code so they agree.

Two related gaps in the needs-a-decision queue, both found reviewing #226. **The season lane has no liveness filter.** The daemon's episode lane filters `AND e.wanted = 1 AND e.state != 'available'` (`crates/arr-daemon/src/attention.rs:260`). The season lane #226 fixed has no equivalent. So a season pack that hard-fails twice, falls back to per-episode grabbing exactly as §6.2 says it should, and is then fully acquired keeps notifying and keeps sitting in the queue for the full 30 days. §5.7 now promises "a target the operator has dealt with stops producing failures and drops out" — a season dealt with *by the system working* does not drop out. **The API and the daemon disagree about the same queue.** The daemon filters `movies.wanted = 1 AND movies.state != 'available'` (`attention.rs:133-141`); the API's `needs_decision` (`crates/arr-api/src/movies.rs:785`) has no such filter. Same for the episode lane — daemon filters, API does not. `GET /api/queues/attention` therefore lists titles that never produce an ntfy notification, which is the queue telling the operator two different stories on two channels. The divergence predates this milestone, but #226's new doc comment at `movies.rs:798-802` asserts "Both hard-fail branches hold to §5.7's bar", which now overstates what the code does. Scope: one liveness rule for all three lanes, applied in both readers, and §5.7 amended to state it. Fix the doc comment or the code so they agree.
naps62-yolo added this to the Feedback pass 2 milestone 2026-08-25 10:30:19 +01:00
naps62-yolo added the area/apidifficulty/moderatetype/bug labels 2026-08-25 10:30:19 +01:00
Author
Owner

Out of scope, found while working this:

crates/arr-api/src/series.rs:734 and :748 are not rustfmt-clean on
blitz/feedback-2, so just ci fails at fmt-check before it runs
anything else. I could not run the gate without fixing it, so this branch
carries a one-commit style(api): reformat two error arms for it. Nothing
else in that file changed.

Out of scope, found while working this: `crates/arr-api/src/series.rs:734` and `:748` are not rustfmt-clean on `blitz/feedback-2`, so `just ci` fails at `fmt-check` before it runs anything else. I could not run the gate without fixing it, so this branch carries a one-commit `style(api): reformat two error arms` for it. Nothing else in that file changed.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: yolo/arr#238