Skip to content

feat(requests): make 4K requests separate from regular requests - #3071

Closed
Brady3035 wants to merge 14 commits into
Silo-Server:mainfrom
Brady3035:Split-request-4k
Closed

Brady3035 wants to merge 14 commits into
Silo-Server:mainfrom
Brady3035:Split-request-4k

Conversation

@Brady3035

@Brady3035 Brady3035 commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

feat(requests): make 4K requests separate from regular requests

Problem

Closes #583
Related issue: N/A
Validation tasks: changes #1202 C1, C2, C3, C4; changes #1203 C1; changes #1204 C1, C2

A user can't choose between an HD and a 4K copy of a title. Today a user whose playback limit allows 4K gets an HD and a 4K copy for every request, and everyone else gets HD only (#583). Admins can't decide who may ask for 4K except through the playback limit. Someone who already has a title in HD can't ask for it in 4K at all, because the title counts as available.

This change makes a 4K request its own request. A regular request gets the HD copy; a 4K request gets the 4K copy alone and goes only to a server that takes 4K. Who may make 4K requests is a new setting next to request approval and limit, set per account, per access group, or server-wide.

Approach

  • One quality per request. media_requests.is_4k marks a 4K request, and the active-request index now keys on it, so a title can have one open regular and one open 4K request. Each is approved, cancelled and counted against the requester's quota on its own. "Also request a 4K version of every title" (force_dual_quality) still adds a 4K copy to regular requests. The requester's playback quality no longer does.
  • Permission. uhd_mode on request_user_limits and request_group_limits (inherit, allowed, denied) and uhd_requests_allowed on request_settings resolve like approval and quota: the account, then its access group, then the server default, which starts off.
  • Routing. A 4K request sends only the 4K tier through the existing routing: under Standard, to the server marked 4K; under Advanced, to the matching rule's 4K destination. Creating one is refused when the account may not (403) or the title's route, decided for the requester, sends no 4K to an enabled server (409). A 4K tier that no route sends, or that a rule skips, becomes a failed target with the reason instead of leaving the request approved with nothing sent.
  • Library. Presence can't tell a 4K file from an HD one, so the library never refuses or completes a 4K request, and a 4K request's state comes from its 4K target rather than the library's season counts: it reads available once that target completes and the title is in the library. With no download server for its media type, an approved 4K request records why, retries and then fails, since the library can't complete it. Follows and watchlist requests stay on a title's regular request.
  • API (v2 only). is_4k on createRequest and on requests; request_4k on the title detail, with reasons 4k_not_allowed and 4k_unavailable; requests_4k on account and group limits and on request usage; requests_4k_default on request settings; requests_4k_supported and requests_4k_allowed on /requests/status. Writes that leave the new fields out keep the stored values, and v1 is unchanged.
  • Web. "Request in 4K" and the 4K request's state on the title page (on a series it opens the same season picker as a regular request, with every season pickable since the library's status is the HD copy's). A title already in the library gets "Request in 4K", "Cancel 4K Request" and the 4K state on its item page; the item page reads the title's request detail only while the viewer may make 4K requests. a 4K requests row in an account's Requests card and in the access group editor, the server default in Settings › Requests, and 4K labels in My requests and the admin queue.

docs/architecture/media-requests.md has a new 4K requests section.

The iOS and Android clients need follow-up work to offer 4K requests; until then they keep making regular requests. jellycompat has no request surface. The user manual needs an issue on siloserver.org for the new settings.

Validation

  • Go: build, gofmt, and go vet ./... clean; lint-changed (golangci-lint v2.12.2) reports 0 issues.
  • Go tests: internal/requests, internal/apiv2, internal/api/..., cmd/silo, internal/contractspec and internal/contractledger pass. New tests cover the 4K permission layering, 4K create refusals and one open request per quality, the 4K check reading the title's own route, the state of a 4K request whose seasons are in the library in HD, and 4K routing under Standard with and without a 4K server. Tests that relied on the playback limit adding a 4K tier were rewritten or removed.
  • Not run: the full make test-go and the Postgres DB-contract tests; there was no local database. The migration ran once, on a test server with existing requests.
  • Contracts: OpenAPI and fixtures regenerated; committed fixtures validate. verify-apiv2-contract (oasdiff against the base) was not run.
  • Web: tsc, lint (no errors), format:check, build and budget:check pass; all tests pass, run one directory at a time because the full run ran out of memory in WSL. A new test covers Cancel on the title page never picking the viewer's 4K request. After the 4K season picker change (bac14b3c5), its two test files, tsrs -b and eslint on the changed files were rerun and pass; the full web suite was not rerun. The item page change (ec893c80c) adds a test of when the 4K request is offered; src/pages/ItemDetail passes.
  • Migrations: goose validate and migrationcheck pass. verify-local-paths passes.
  • Manual: on a test server with Sonarr and a Sonarr marked 4K, a regular account requested a series in 4K beside its regular request, and the request showed in the admin queue as 4K and pending. On a series the library has in HD, the same account requested the latest season in 4K from the item page, saw "4K: Requested" and "Cancel 4K Request", and cancelled it.

Evidence

Evidence: https://evidence.siloserver.org/r/silo-server/pr-3071/

Surface and build: web app and web admin at desktop and phone width. Before is 6de6d5e5e (main); after is this branch. Pairs cover the title page, the 4K season picker, the item page's menu, My requests, the admin request queue, an account's Requests card, the access group editor and Settings › Requests.

Risks

  • Behavior change. Users whose playback limit allows 4K stop getting a 4K copy with each request, and 4K requests start off for everyone. Admins who want 4K turn on "Allow 4K requests", or "Also request a 4K version of every title" to keep a 4K copy on every request. The Apple and Android clients use v2 but don't read is_4k yet, so their users can't make 4K requests until those clients add it. Until then, Cancel on a title in either app can pick a 4K request made from the web, because both apps cancel the newest request on the title.
  • Migration. It rebuilds idx_media_requests_active_tmdb with is_4k and adds columns with defaults. Existing requests become regular requests and keep any 4K target they already have. The down migration deletes 4K requests, since the old title-only index can't hold both.
  • Routing. A route whose 4K destination is a Seerr with its 4K switch off still counts as taking 4K, so a 4K request sent there fails as [bug] Advanced routes can send 4K to a Seerr whose 4K switch is off #2634 describes.
  • Notifications. The "available" notification for a 4K request fires once its 4K target completes and the title is in the library, which may still be the HD copy if the 4K file isn't scanned yet.

Checklist

  • I read and can explain the complete diff.
  • This pull request addresses one concern.
  • Each test this pull request adds meets "Decide what to test" in CONTRIBUTING.md.
  • The Evidence section shows every change a user can see, or says there is none.

AI Disclosure

  • Harness: Claude Code
  • Tool(s): Claude Code
  • Model(s): claude-opus-5-5
  • Involvement: Fully AI-generated, human verified
  • Adversarial review: Claude Code /code-review (high effort) over the full diff, checking correctness, regressions and cost on hot paths. It raised 10 findings. Fixed: HD season counts making an open 4K request read as available; the title page's Cancel picking the viewer's 4K request; the 4K check ignoring rule conditions and disabled servers; /requests/status failing on a 4K lookup error; repeated policy and routing reads; reason ordering for blocked accounts; and the dead MaxPlaybackQuality resolver method and stale comments. Not changed: 4K defaulting off with no v1 path, and the 4K notification gate, both covered under Risks.

Note

Add 4K requests as a separate request type alongside regular requests

  • 4K is now a request type with its own is_4k flag, active-request index, and quality selection (requestQualities picks 2160p for 4K requests, 1080p for regular, both under force-dual) in service.go
  • Adds 4K permission settings at server, group, and account levels with inherit/allowed/denied modes, resolved through EffectivePolicy.AllowUHD and exposed via admin APIs and the UI in group_limits.go and admin_requests.go
  • 4K requests are validated for permission and delivery (ensureUHDRequestable, uhdTitleDeliverable) with new ErrUHDNotAllowed/ErrUHDUnavailable errors; unrouted 4K targets now record a failure instead of being silently dropped
  • Removes the playback-quality entitlement ceiling (MaxPlaybackQuality); force-dual is driven by settings via ForceDualQuality instead of entitlement lookups
  • Frontend adds 4K request/cancel actions, status, and 4K season picker via useDetail4KRequest in useDetail4KRequest.tsx
  • Behavioral Change: migration 20261025160750_request_4k.sql replaces the active-request unique index with one including quality (regular and 4K requests can coexist per title); rolling back deletes all 4K requests. Follow lookups, library presence, and watchlist handling now exclude 4K requests

Macroscope summarized 3865d68.

Brady3035 and others added 2 commits October 25, 2026 11:55
A request now asks for one quality. A regular request gets an HD copy (plus
a 4K one while "Also request a 4K version of every title" is on); a 4K
request gets a 4K copy alone, sent only to a server that takes 4K. A title
can have one open request of each, so someone can ask for 4K of a title the
library already has in HD.

Who may make 4K requests is a new setting beside request approval and
limit, resolved the same way: the account, then its access group, then a
server-wide default that starts off. The requester's playback quality no
longer adds a 4K copy to their requests.

- media_requests.is_4k, with the active-request index keyed on it;
  request_user_limits/request_group_limits.uhd_mode and
  request_settings.uhd_requests_allowed.
- v2 API: is_4k on createRequest and requests, request_4k on the title
  detail, requests_4k on account and group limits, requests_4k_default on
  request settings, requests_4k on request usage, and
  requests_4k_supported/requests_4k_allowed on request status. Writes that
  leave the new fields out keep the stored values; v1 is unchanged.
- The library never refuses or completes a 4K request, since presence
  cannot tell a 4K copy from an HD one; only its 4K target completes it.
- A 4K tier no route sends now fails visibly instead of being dropped.
- Web: "Request in 4K" on the title page, a 4K row in an account's
  Requests card and the access group editor, the server-wide default in
  Settings > Requests, and 4K labels in request lists.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
- A 4K request's state comes from its 4K target. The library's season
  counts are its HD copy's, so they no longer make an open 4K series
  request read as available.
- Creating a 4K request decides the title's 4K tier the way submission
  will, so a rule's conditions count and a disabled server does not. It
  runs after the checks every request gets, so a blocked account is told
  it is blocked, and it reuses the resolved policy.
- request_4k on the title detail reports the reasons any request can have
  before the 4K ones.
- /requests/status logs a 4K lookup failure and reports no 4K instead of
  failing, and reads the routing setup once.
- The title page's Cancel never picks the viewer's 4K request for the
  regular one.
- The requests service no longer asks for the playback-quality ceiling;
  EntitlementResolver is now the content-rating lookup alone.
- The route editor's 4K caption no longer mentions the playback limit.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@silo-triage silo-triage Bot added the size/XXL 1000–2999 added + deleted lines (all files); change volume, not priority. label Oct 25, 2026
@silo-kody

silo-kody Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌

@coderabbitai

coderabbitai Bot commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review.

Walkthrough

The change adds standalone 4K requests with separate permissions, routing, persistence, and request state. It also adds API and web controls for configuring 4K access and creating and tracking 4K requests.

Changes: 4K Request Support

Layer / File(s) Summary
Policy and request data
migrations/sql/*, internal/requests/types.go, internal/requests/repository.go, internal/requests/group_limits.go, internal/requests/service.go
The data model and storage add 4K request flags and inherited permission modes. Effective policy resolves account, group, and server settings.
Request lifecycle and routing
internal/requests/service.go, internal/requests/routing*.go, internal/requests/follows.go, internal/requests/watchlist.go, internal/requests/*_test.go, docs/architecture/media-requests.md
4K requests target 2160p only. Creation checks permission and server availability. Request state and completion remain separate from regular requests.
API and contract integration
internal/apiv2/*, contracts/api/v2/*, web/src/api/*, docs/admin-users-api.md
The API and schemas expose 4K policies, support and eligibility, request flags, and separate title request state. Fixtures and API documentation include the added fields.
Admin policy controls
web/src/lib/requestAccess*, web/src/components/admin/RequestLimitFields.tsx, web/src/pages/AdminAccessGroups*, web/src/pages/admin-settings/*, web/src/pages/admin-users/detail/access/*
Admin interfaces resolve and edit 4K permissions at the server, access-group, and account levels.
Request actions and status
web/src/pages/ItemDetail/components/*, web/src/pages/ItemDetail/*Content.tsx, web/src/pages/Requests.tsx, web/src/pages/admin-requests/queueParts.tsx, web/src/lib/mediaRequests.ts, web/src/components/RequestSeasonsDialog*, web/src/hooks/queries/useRequests.ts
The item page offers separate 4K request and cancellation actions, with 4K season selection and status. User and admin lists identify 4K requests.

Estimated code review effort: 4 (Complex) | ~60 minutes

Change: Feature · Severity of issue fixed: Medium

Sequence Diagram(s)

sequenceDiagram
  actor Viewer
  participant RequestActionBar
  participant RequestsAPI
  participant RequestService
  participant RequestRepository
  Viewer->>RequestActionBar: Select "Request in 4K"
  RequestActionBar->>RequestsAPI: Send is_4k=true
  RequestsAPI->>RequestService: Submit request
  RequestService->>RequestRepository: Check and store 4K request
Loading

Suggested labels: javascript, needs-review, impact: usability

Suggested reviewers: quick104

Merge Risk: Minimal · previous review 6d7de

The reviewed changes have no established current-head merge risk.

Security architecture risk: Moderate · up to 6d7de

4K requests retain server-side permission checks and shared account quotas. The main design risk is downgrade recovery: reverting the database deletes all standalone 4K requests and their tracking records, even when external download work may still be running.

Retained concerns

  • Medium · reliability · inferred: Downgrade deletes all standalone 4K requests, including live ones, and cascades their local fulfillment targets and follows. Already-submitted external work can consequently lose its local ownership and reconciliation records without being cancelled. The migration explicitly acknowledges data loss and requires operator action; this is a rollback-containment concern, not a demonstrated user authorization bypass.
Security review details

Security Blast Radius

  • inferred — The demonstrated new authority is for eligible accounts to cause 2160p fulfillment on administrator-configured download destinations, including for titles already present in HD. It remains subject to account request quotas and content policy. Separately, downgrade deletion applies to every standalone 4K request in the affected database.

Security Findings and Attack Paths

  • inferred — A direct API caller can bypass the web eligibility display and submit is_4k, but the traced mutation path still resolves authenticated identity and checks effective 4K permission and routing before storage. No new authorization-bypass attack path was substantiated in this inspected flow; this conclusion does not establish complete security coverage.

Trust Boundaries and Controls

  • observed — User and profile identity come from request context rather than create-request fields. The service preserves administrative approval authority and owner-or-administrator cancellation checks. Request title and year are replaced with server-fetched metadata when available before routing facts are captured.

Resilience and Maintainability Implications

  • inferred — Normal cancellation deliberately preserves local ownership after external submission, whereas downgrade removes that ownership without an equivalent lifecycle guard. Safe operational recovery therefore depends on preserving records and handling outstanding external work outside this SQL reversal.

Hardening Proposals

  • proposed — Make the destructive downgrade precondition explicit: preserve a recoverable backup or export of 4K ownership records and drain or externally reconcile live fulfillment before removing them. A refusal or explicit destructive override when such records exist would make this boundary harder to cross accidentally.
Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title "feat(requests): make 4K requests separate from regular requests" matches the main change in the changeset. The raw summary shows the core work: an is_4k flag on requests, a 4K-specific pe…
Linked Issues check Passed [#583] requires that, with force_dual_quality=false, one request must not create both 1080p and 2160p targets implicitly. It also requires an explicit per-request quality choice, with exclusive 2160p …
Out of Scope Changes check Passed The changes connect to the #583 fix or to the explicit 4K request model it requires. Connected groups: (a) Quality model: media_requests.is_4k, the active-request index keyed on quality, and the migra…
Description check Passed The pull request description directly explains the separate 4K request feature, including permission handling, routing, API changes, web UI changes, migration impact, testing, and known risks. It matc…
Full details: Title check

Explanation

The title "feat(requests): make 4K requests separate from regular requests" matches the main change in the changeset. The raw summary shows the core work: an is_4k flag on requests, a 4K-specific permission layer (UHDMode), 4K-only routing, the migration that changes the active-request index, and the matching web and API updates. The title is specific and concise, and it follows a conventional commit style.

Full details: Linked Issues check

Explanation

[#583] requires that, with force_dual_quality=false, one request must not create both 1080p and 2160p targets implicitly. It also requires an explicit per-request quality choice, with exclusive 2160p available for 4K. The PR meets both points. Evidence from the reviewed summary and tests: (1) The entitlement-based playback-quality ceiling is removed (MaxPlaybackQuality removed from internal/requests/entitlements.go and the EntitlementResolver interface in service.go). Requested qualities now come from Is4K and ForceDualQuality. (2) A regular request targets HD (1080p) only. ForceDualQuality adds 2160p only to regular requests (service_test.go). (3) A 4K request (is_4k=true on createRequest, requests.go) targets 2160p alone (service_test.go; routing_mode_test.go for Standard routing with and without a 4K-marked server). This provides the exclusive quality choice the issue asks for. (4) The force_dual_quality setting text (RequestsSettings.tsx, requestRoutingModel.ts) now states that it adds a 4K copy to regular requests, which meets the issue's clarity request for an intentional dual-target setting. Remaining uncertainty is validation only, not requirement coverage: make test-go and Postgres DB-contract tests were not run, and the full web suite was not rerun after later commits. The incremental changes since the previous review (4K season picker, item-page menu, polling) affect 4K UI and do not alter the quality rule for #583. The previous PASS is still supported.

Full details: Out of Scope Changes check

Explanation

The changes connect to the #583 fix or to the explicit 4K request model it requires. Connected groups: (a) Quality model: media_requests.is_4k, the active-request index keyed on quality, and the migration 20261025160750_request_4k.sql. (b) Permission layering (uhd_mode and uhd_requests_allowed): this replaces the playback-quality gate that previously decided who could receive a 4K target, so it is needed for the change. (c) Routing: 4K tier routing and failed-target recording for unsent 4K tiers, which prevent a silent empty 4K request. (d) Library handling: 4K requests do not use HD library presence, which keeps 4K state correct. (e) v2 API fields, OpenAPI, fixtures and web types: exposure of the new fields. (f) Web controls, admin settings, and the item-page and My requests labels: user and admin surfaces for the new fields. (g) Docs: media-requests.md and admin-users-api.md. The changes are broad. Some surfaces, such as the 4K notification gate and the Seerr 4K switch handling, follow from separating 4K requests and are described in the PR Risks section. No change is shown to be unrelated to #583 or to the separate-request model. The PR body reference to validation tasks #1202, #1203 and #1204 is not a linked issue in this assessment, so it is not assessed here.

Full details: Description check

Explanation

The pull request description directly explains the separate 4K request feature, including permission handling, routing, API changes, web UI changes, migration impact, testing, and known risks. It matches the changeset.

Finishing Touches

🧪 Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 684ade02-8648-47a6-9f50-9d62a45334cc
Commits

Reviewing files that changed from the base of the PR and between ec893c8 and 6d7dee2.

Files selected for processing: 4

  • web/src/hooks/queries/useRequests.test.tsx
  • web/src/hooks/queries/useRequests.ts
  • web/src/pages/ItemDetail/components/useDetail4KRequest.test.tsx
  • web/src/pages/ItemDetail/components/useDetail4KRequest.tsx
Files skipped from review as they are similar to previous changes: 1

  • web/src/pages/ItemDetail/components/useDetail4KRequest.test.tsx

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 1 remain after this review.

@macroscopeapp

macroscopeapp Bot commented Oct 25, 2026

Copy link
Copy Markdown

The changed 4K routing caption in web/src/pages/admin-settings/requestRoutingModel.ts is used by the fallback editor, rule editor, and rule presets, but those routing screens are not identified in the Evidence section. The linked evidence page should include before-and-after captures of the affected routing screens (desktop and mobile where the copy is visible).

Suggested fix: add those captures to the linked evidence page.

Automated check: Macroscope check run agent (gpt-6-luna). Evidence was not reviewed for correctness.

Posted via Macroscope — Visible change evidence

@silo-triage silo-triage Bot added api-v2 API v2 / Huma migration program (epic #135); long-running, stacked by phase enhancement New feature or request go Pull requests that update go code priority: P2 Limited scope, workaround exists, or polish labels Oct 25, 2026
@Brady3035 Brady3035 changed the title Split request 4k feat(requests): make 4K requests separate from regular requests Oct 25, 2026
@coderabbitai coderabbitai Bot added evidence-required Needs before-and-after evidence before the Evidence check passes impact: playback Can't play, stalls, or wrong media impact: usability Core flow broken or severely blocked javascript Pull requests that update javascript code needs-review Needs maintainer review to resolve uncertain classification, scope, or changed evidence. size/XXXL 3000+ added + deleted lines (all files); change volume, not priority. labels Oct 25, 2026
Comment thread internal/requests/service.go Outdated
Comment on lines +1461 to +1463
if decision, ok := decideRoutes(routes, req, []Quality{Quality2160p})[Quality2160p]; !ok || decision.Skip {
return ErrUHDUnavailable
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

kody code-review Bug high

Missing integration validation in ensureUHDRequestable allows a title-specific routing decision to select a disabled server when another rule references an enabled 4K server, so the global check passes and creation consumes quota for a request that routedConnection refuses. Validate the selected decision's integration before accepting it.

Prompt for LLM

File internal/requests/service.go:

Line 1461 to 1463:

Missing integration validation in ensureUHDRequestable allows a title-specific routing decision to select a disabled server when another rule references an enabled 4K server, so the global check passes and creation consumes quota for a request that routedConnection refuses. Validate the selected decision's integration before accepting it.

Talk to Kody by mentioning @kody

Was this suggestion helpful? React with 👍 or 👎 to help Kody learn from this interaction.

​

​

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a title's 4K tier now counts only if the server its own route picks
is enabled. Before, an enabled 4K server on some other rule was enough. A test covers it.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks—that addresses the reported issue. Checking the server selected by the title’s own 4K route prevents an unrelated enabled server from making the request appear deliverable. The regression test covers the failure case I flagged.

Comment thread internal/requests/service.go Outdated
Comment on lines +1530 to +1535
deliverable, err := s.uhdDeliverable(ctx, mediaType)
if err != nil {
return RequestState{}, err
}
if !deliverable {
return RequestState{Reason: ReasonUHDUnavailable}, nil

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

kody code-review Bug medium

Incorrect 4K availability in the title detail exposes a "Request in 4K" action whenever any route supports the media type, even when the title's matching rule skips 4K, causing CreateRequest to reject the action with ErrUHDUnavailable. Evaluate the title's captured routing facts with the same admission logic used by creation.

Prompt for LLM

File internal/requests/service.go:

Line 1530 to 1535:

Incorrect 4K availability in the title detail exposes a "Request in 4K" action whenever any route supports the media type, even when the title's matching rule skips 4K, causing CreateRequest to reject the action with ErrUHDUnavailable. Evaluate the title's captured routing facts with the same admission logic used by creation.

Talk to Kody by mentioning @kody

Was this suggestion helpful? React with 👍 or 👎 to help Kody learn from this interaction.

​

​

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the title page now runs the same per-title routing check as
creating the request. It no longer offers "Request in 4K" for a title whose rule skips 4K

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That addresses the reported issue: using the same per-title routing check for the title page and request creation prevents offering “Request in 4K” when the title’s matching rule skips 4K. No further change is needed for this suggestion if both paths now share that check.

ALTER TABLE public.request_settings DROP COLUMN IF EXISTS uhd_requests_allowed;

DROP INDEX IF EXISTS public.idx_media_requests_active_tmdb;
CREATE UNIQUE INDEX IF NOT EXISTS idx_media_requests_active_tmdb

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

kody code-review Kody Rules high

Prolonged ACCESS EXCLUSIVE locks during rollback keep request_group_limits, request_user_limits, and request_settings unavailable throughout the media_requests index scan because the transaction retains locks from dropping their columns while rebuilding idx_media_requests_active_tmdb. Separate the metadata-only rollback changes from a resumable concurrent index rebuild outside the Goose transaction and multi-statement StatementBegin block, and coordinate rollback to prevent new 4K requests from invalidating the restored uniqueness constraint.

Also found in:

  • migrations/sql/20261025160750_request_4k.sql:12-12

Kody rule violation: Make denormalization migrations resumable with bounded lock and retry costs

Prompt for LLM

File migrations/sql/20261025160750_request_4k.sql:

Line 42:

Prolonged ACCESS EXCLUSIVE locks during rollback keep request_group_limits, request_user_limits, and request_settings unavailable throughout the media_requests index scan because the transaction retains locks from dropping their columns while rebuilding idx_media_requests_active_tmdb. Separate the metadata-only rollback changes from a resumable concurrent index rebuild outside the Goose transaction and multi-statement StatementBegin block, and coordinate rollback to prevent new 4K requests from invalidating the restored uniqueness constraint.

**Also found in:**
- `migrations/sql/20261025160750_request_4k.sql:12-12`

Talk to Kody by mentioning @kody

Was this suggestion helpful? React with 👍 or 👎 to help Kody learn from this interaction.

​

​

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This matches the repo's other request migrations: one goose
transaction, run in maintenance. The down migration only runs on an explicit rollback, and
splitting out a concurrent index build adds a non-transactional step for a path that is rarely
used. Happy to change it if maintainers want concurrent index builds here

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That’s reasonable. With migrations run in maintenance and request writers stopped, the transactional rollback is a defensible choice: it keeps the deletion, schema changes, and restored uniqueness constraint atomic without adding a non-transactional recovery path.

The locks do last through the index rebuild, but that alone doesn’t justify a high-severity finding under this operating model. A concurrent build would matter if requests needed to remain available during migration; it isn’t inherently preferable for an explicit maintenance rollback.

I wouldn’t require a change here. The useful caveat is that the maintenance window must accommodate the deletion and index rebuild. Rarity alone doesn’t reduce their cost, but the stated maintenance procedure addresses the availability concern.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3


Review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 9417332f-173d-4763-9f69-b795c83a2eda
Commits

Reviewing files that changed from the base of the PR and between 6de6d5e and e3aadf2.

Files selected for processing: 59
  • cmd/silo/main.go
  • contracts/api/v2/fixtures/admin_request_limit_ok.json
  • contracts/api/v2/fixtures/admin_request_settings_ok.json
  • contracts/api/v2/fixtures/admin_request_user_usage.json
  • contracts/api/v2/fixtures/admin_requests_ok.json
  • contracts/api/v2/fixtures/cancel_request_ok.json
  • contracts/api/v2/fixtures/create_request_ok.json
  • contracts/api/v2/fixtures/list_my_requests_ok.json
  • contracts/api/v2/fixtures/request_status_ok.json
  • contracts/api/v2/openapi.json
  • docs/admin-users-api.md
  • docs/architecture/media-requests.md
  • internal/api/router.go
  • internal/apiv2/admin_request_groups.go
  • internal/apiv2/admin_request_usage.go
  • internal/apiv2/admin_requests.go
  • internal/apiv2/request_lifecycle.go
  • internal/apiv2/requests.go
  • internal/requests/api_key_optional_test.go
  • internal/requests/editor_concurrency.go
  • internal/requests/entitlements.go
  • internal/requests/errors.go
  • internal/requests/follows.go
  • internal/requests/group_limits.go
  • internal/requests/group_limits_test.go
  • internal/requests/lifecycle_guard_test.go
  • internal/requests/repository.go
  • internal/requests/router_seasons.go
  • internal/requests/router_seasons_test.go
  • internal/requests/routes_admin.go
  • internal/requests/routing.go
  • internal/requests/routing_mode_test.go
  • internal/requests/routing_test.go
  • internal/requests/seerr_4k_test.go
  • internal/requests/service.go
  • internal/requests/service_test.go
  • internal/requests/store.go
  • internal/requests/types.go
  • internal/requests/watchlist.go
  • migrations/sql/20261025160750_request_4k.sql
  • web/src/api/types.ts
  • web/src/api/v2/adminRequests.ts
  • web/src/api/v2/schema.ts
  • web/src/components/admin/RequestLimitFields.tsx
  • web/src/lib/mediaRequests.ts
  • web/src/lib/requestAccess.test.ts
  • web/src/lib/requestAccess.ts
  • web/src/pages/AdminAccessGroups.test.tsx
  • web/src/pages/AdminAccessGroups.tsx
  • web/src/pages/ItemDetail/components/RequestActionBar.test.tsx
  • web/src/pages/ItemDetail/components/RequestActionBar.tsx
  • web/src/pages/Requests.tsx
  • web/src/pages/admin-requests/queueParts.tsx
  • web/src/pages/admin-settings/RequestRouting.test.tsx
  • web/src/pages/admin-settings/RequestsSettings.tsx
  • web/src/pages/admin-settings/requestRoutingModel.ts
  • web/src/pages/admin-users/detail/access/RequestsCard.tsx
  • web/src/pages/admin-users/detail/access/policySources.test.ts
  • web/src/pages/admin-users/detail/access/policySources.ts
Files with no reviewable changes: 1
  • internal/requests/api_key_optional_test.go

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 3 remain after this review.

Comment thread internal/requests/service.go Resolved
Comment thread web/src/lib/requestAccess.ts Resolved
- A title's 4K tier counts as deliverable only when the server its route
  chooses is enabled, not when some other rule's 4K server is.
- The title detail's request_4k uses the same per-title routing check as
  creating the request, so it no longer offers 4K for a title whose rule
  skips it.
- A failure while checking 4K routing on the title detail logs a warning and
  reports 4k_unavailable instead of failing the whole page.
- The title page lets the viewer cancel their own pending 4K request, beside
  the regular one.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@macroscopeapp

macroscopeapp Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

The added 4K permission layer extends the request-policy behavior covered by these previously passed cases: #1196 C1–C2 (Server, 7cc2c1f2) and #1197 C1–C2 (Web admin, build 807 · d4e35ba9). The PR should explain why the validated policy behavior changes; these cases need re-validation after merge.

Correction: #1202 C1–C4, #1203 C1, #1204 C1–C3, and silo-apple#328/#329 and silo-android#338/#339 are all marked Not run. They have no prior results to invalidate; keep them only as planned validation scope. The earlier comment incorrectly described these as previously validated.

Suggested fix: update the PR description to:
Validation tasks: changes #1196 C1, C2; changes #1197 C1, C2; changes #1202 C1, C2, C3; changes #1203 C1; changes #1204 C1, C2, C3

Posted via Macroscope — v1 validation impact

Automated check: Macroscope check run agent (gpt-6-luna). No validation was performed.

Posted via Macroscope — v1 validation impact

@silo-triage silo-triage Bot removed the size/XXXL 3000+ added + deleted lines (all files); change volume, not priority. label Oct 25, 2026
@silo-kody

silo-kody Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌

@coderabbitai coderabbitai Bot removed impact: playback Can't play, stalls, or wrong media evidence-required Needs before-and-after evidence before the Evidence check passes labels Oct 25, 2026
@Brady3035

Copy link
Copy Markdown
Contributor Author

I think this should be ready for review. Thanks!

@Brady3035

Copy link
Copy Markdown
Contributor Author

I'll add the requested evidence later today.

"Request in 4K" on a series sent a request for every aired season, while
the regular Request button opens the season picker. It now opens the same
picker in 4K mode, which reads request_4k and sends is_4k. The seasons'
library and request status describe the HD copy and the regular request,
so in 4K every season can be picked and none shows a status.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@silo-kody

silo-kody Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌

const allowed =
enabled &&
Boolean(featureStatus.data?.requests_enabled && featureStatus.data.requests_4k_allowed);
const detail = useRequestMediaDetail(mediaType, tmdbID, { enabled: allowed }).data;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

kody code-review Bug medium

Stale library-item 4K progress occurs because useRequestMediaDetail checks only request.download in its polling predicate and ignores request_4k.download, preventing automatic refreshes for titles already available in HD with only a 4K download running. Update the shared hook to poll when either quality has a download.

Prompt for LLM

File web/src/pages/ItemDetail/components/useDetail4KRequest.tsx:

Line 45:

Stale library-item 4K progress occurs because useRequestMediaDetail checks only request.download in its polling predicate and ignores request_4k.download, preventing automatic refreshes for titles already available in HD with only a 4K download running. Update the shared hook to poll when either quality has a download.

Talk to Kody by mentioning @kody

Was this suggestion helpful? React with 👍 or 👎 to help Kody learn from this interaction.

​

​

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in f17ec2e: the title detail now polls while either its regular or its 4K request downloads.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing this in f17ec2edf. Polling while either request.download or request_4k.download is active addresses the reported stale 4K progress issue on titles already available in HD.

The title's request detail polled only while its regular request was
downloading, so a 4K download alone never refreshed its progress. That is
the usual case for a title in the library in HD. Poll while either request
downloads.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@silo-kody

silo-kody Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2


Review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 74c11e5e-a324-4cda-bc97-3c3edbb63c95
Commits

Reviewing files that changed from the base of the PR and between bac14b3 and ec893c8.

Files selected for processing: 7
  • web/src/pages/ItemDetail/MovieContent.tsx
  • web/src/pages/ItemDetail/SeriesContent.tsx
  • web/src/pages/ItemDetail/components/ActionBar.tsx
  • web/src/pages/ItemDetail/components/RequestActionBar.tsx
  • web/src/pages/ItemDetail/components/useDetail4KRequest.test.tsx
  • web/src/pages/ItemDetail/components/useDetail4KRequest.tsx
  • web/src/pages/ItemDetail/components/useOwnCancellableRequest.ts

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 2 remain after this review.

The overflow menu closes on click, so "Request in 4K" for a movie could be
pressed again while the first request was still sending; the server refused
the second one as already requested and the viewer saw an error. Offer the
action only while no request is sending, as the request page's 4K button
does.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@silo-kody

silo-kody Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌
⚠️ 2 Kody Rule(s) were not evaluated

These rules declare that they need repository context beyond this diff, and the review could not retrieve it, so they were not judged on this pull request:

  • Preserve optional store capabilities through production wrappers
  • Detach mandatory cleanup from request cancellation and bound its lifetime

@Brady3035

Copy link
Copy Markdown
Contributor Author

Geez those bots tore this apart lol, think it's good now

@Brady3035

Copy link
Copy Markdown
Contributor Author

Ready to go here.

Quick104 and others added 2 commits October 30, 2026 15:50
…quests

The 4K deliverability check on create and on the title detail now decides
the title's 4K route for the requester, so a rule limited to certain
requesters counts for them. An approved 4K request with no download server
for its media type records why, retries, and then fails; the library never
completes a 4K request, so it no longer stays approved for good.

Also documents the 4K request fields in the API contract and drops two
stale references to the removed playback-quality rule.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…the library

A completed 4K request read as available as soon as its 4K target finished,
before Silo had scanned anything in, so My requests could offer a title that
could not be opened yet. It now stays processing until the title is in the
library, as a regular request does.

Co-Authored-By: Claude Opus 5.5 <[email protected]>

@Quick104 Quick104 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 Claude Code (claude-opus-5-5)

Review of 65ea571. The approach answers #583: each request asks for one quality, and an admin decides who may ask for 4K. The findings are on the lines. Three more don't fit a line:

  • Low: the API contract document doesn't cover the new fields. docs/architecture/api-contract.md records each earlier request addition (follow_supported, watchlist_requests and others) but has nothing for is_4k, request_4k, requests_4k_* or requests_4k_default. I'm adding a paragraph on this branch, so there's no need to change it yourself.
  • Maintainer decision: the Apple and Android apps can cancel the wrong request. Both apps already use /api/v2/requests, not v1 as the description says. Both pick the newest active request the account owns for a title and cancel that one (Apple RequestDetailCache.currentRecord, Android RequestDetailCache.kt). Neither looks at quality. Once someone makes a 4K request from the web, Cancel on that title in an app withdraws the 4K request while the screen shows the regular one. 4K requests start off, so nothing happens until an admin turns them on. The apps need to read is_4k before that.
  • Disclosed: the "available" notification for a 4K request uses the HD copy. notifyFulfilledPending still checks title presence, so the notification can fire before the 4K file is scanned in. This is listed under Risks and has the same root cause as the line comment on service.go:1379.

The fixes for the first three line findings and the contract paragraph follow in commits on this branch. A summary comment with the review's verdict will follow.

Comment thread internal/requests/service.go Resolved
Comment thread internal/requests/service.go Resolved
Comment thread internal/requests/types.go Resolved
// open 4K request, or whether the viewer may make one now.
func (s *Service) uhdRequestState(ctx context.Context, viewer Viewer, policy EffectivePolicy, mediaType MediaType, detail *tmdb.MediaDetail) (RequestState, error) {
tmdbID := detail.ID
open, err := s.store.ListActiveByTMDB(ctx, mediaType, []int{tmdbID}, true)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maintainer decision: a finished 4K request can be made again. The 4K state reads only open 4K requests, and the library check is off for 4K, so nothing remembers that a 4K request completed. Afterwards, the title page offers "Request in 4K" again, with no "4K: Available" state, and a new request uses quota and goes to the 4K server again.

Options: leave it as is, treat the latest completed 4K request as the title's 4K state, or have the library lookup read file resolution so 4K presence can be checked. This is the same gap behind the "available" notification noted under Risks. No change on this branch until that's settled.

const allowed =
enabled &&
Boolean(featureStatus.data?.requests_enabled && featureStatus.data.requests_4k_allowed);
const detail = useRequestMediaDetail(mediaType, tmdbID, { enabled: allowed }).data;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maintainer decision (cost, not measured): every library item page reads the full request detail. While the viewer may make 4K requests, each movie and series page calls getRequestMediaDetail just for request_4k. On the server that runs the TMDB detail (cached), recommendation enrichment for about 20 titles, season lookups and, in uhdRequestState, the fulfillment context and routing facts. It refetches every 30 seconds while a download runs. /requests/status also builds the fulfillment context on each read for such viewers. I traced this but did not measure it. A lighter read, for example request_4k on the library item response, would be a contract addition, so I'm leaving it for the maintainers.

@silo-kody

silo-kody Bot commented Oct 30, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌

@Quick104

Quick104 commented Oct 30, 2026 •

Copy link
Copy Markdown
Contributor

🤖 Claude Code (claude-opus-5-5)

Review summary

Reviewed head: 6bb467f. This head is the PR as reviewed at 65ea571 plus two fix commits from this review.

The approach answers #583. Each request now asks for one quality, a title can have one open regular and one open 4K request, and who may ask for 4K is a permission layered like the quota and approval. That is simpler than tying 4K to the playback limit, and it's the shape other request tools use.

Fixed on this branch

  • bcbdee5b7: the 4K check on create and on the title page now decides the title's route for the requester, so a 4K rule limited to some accounts counts for them. An approved 4K request with no download server for its media type now records why, retries and then fails, where before it stayed approved for good. api-contract.md now covers the 4K fields. Two stale mentions of the removed playback-quality rule are gone.
  • 6bb467fa8: a completed 4K request reads available only once the title is in the library, as a regular request does.

Each fix has a test that failed on 65ea571. I also updated the description: the Apple and Android apps use v2, the validation line, and the two behaviors above.

Left for the maintainers

  • The Apple and Android apps can cancel the wrong request. Both apps cancel the newest active request the account owns for a title, without looking at quality. Once someone makes a 4K request from the web, Cancel on that title in an app withdraws it. 4K requests start off, so this waits for an admin to turn them on. Both apps need issues or PRs to read is_4k before this ships, and that same work would let their users make 4K requests.
  • A finished 4K request can be made again, and its "available" notification uses the HD copy. The library can't tell a 4K file from an HD one, so after a 4K request completes the title page offers "Request in 4K" again. The options are to leave it, to treat the latest completed 4K request as the title's 4K state, or to make the library lookup read file resolution. The last fixes both problems.
  • Cost on item pages. While a viewer may make 4K requests, every library movie and series page loads the full request detail to read request_4k, and /requests/status builds the routing context on each read. I traced this but didn't measure it. A lighter read would be a contract addition.

Checks

  • Tests: the PR's new Go tests don't build on the base, which is expected for a new feature, so they don't count toward validation. The three tests added in this review failed on 65ea571 and pass now. go test for internal/requests, internal/apiv2 and internal/api/..., the changed web routing test, and lint-changed pass. I didn't run the change on a server.
  • Cross-provider review (Codex, gpt-6.1-sol, one round on 65ea571): it found the routerless 4K request and the early "Available" state, both fixed above, and the app cancel problem, left for the maintainers above.
  • CI: ci / Web test (4/4) fails on this head in MovieContent.test.tsx › "hands the page's library scope to the match and split dialogs". That test fails on main too ([bug] MovieContent web test fails on main without a QueryClient #3281): it was added in fix(web): scope match and split searches for items in several libraries #2721 and renders without a QueryClient. test(web): render MovieContent in a QueryClient in the library scope test #3282 fixes it. This branch didn't cause it.
  • Earlier bot threads: the migration lock comment and the requests_4k field comment have the author's answers, and I agree with both.

Validated features

I couldn't read the validation board's project data. From the validators' results on the tasks, no passed case regresses. These cases change in minor ways: #1202 C1 (a regular request no longer gets 4K from the playback limit), C2 (a 4K request is not refused when the title is in the library), C3 (library completion skips 4K requests), C4 (routers receive 1080p alone unless the request is 4K or every request asks for 4K); #1203 C1 (the limit editors gain a 4K row); #1204 C1 and C2 (title and item pages gain the 4K action and state). The description's Validation tasks: line now lists them.

User manual

The requests page in the manual (Running a server › Requests) doesn't describe 4K behavior, and this PR adds a setting there, a row in each account's and access group's Requests section, and a new request action. It needs a siloserver.org issue covering the requests and access group pages. None exists yet.

Apple and Android

The apps need follow-up for 4K requests and for the cancel problem above. Neither repository has an issue or PR linked yet. jellycompat has no request surface.

Verdict

Fit: 7/10 · Readiness: 7/10 — conditional (assuming CI is green)

  • Fit: it fixes a real request problem in the core flow with the model admins expect. It adds a permission, settings and API fields, which is new surface area during the QA phase, and the apps aren't ready for it yet.
  • Readiness: the verified defects are fixed and tested, but the app cancel problem should be settled before admins can turn 4K on, the completed-4K behavior needs a decision, and nobody has run the fixed branch on a server.

# Conflicts:
#	contracts/api/v2/fixtures/list_home_sections_item_limit_out_of_range.json
#	contracts/api/v2/fixtures/list_library_sections_item_limit_out_of_range.json
#	contracts/api/v2/fixtures/request_status_ok.json
#	contracts/api/v2/openapi.json
#	internal/apiv2/request_lifecycle.go
#	internal/requests/service.go
#	web/src/api/v2/schema.ts
#	web/src/pages/ItemDetail/SeriesContent.tsx
@Brady3035

Copy link
Copy Markdown
Contributor Author

Just updated the branch to keep it ready for merge

The restore's authority comparison and stricter-flag carry predate the
4K request settings. Read uhd_requests_allowed and the account and
group uhd_mode into the compared request policy, count a restored 4K
allowance as wider, keep request_settings.uhd_requests_allowed off when
the live server has it off, and classify media_requests.is_4k.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@silo-kody

silo-kody Bot commented Nov 6, 2026 •

Copy link
Copy Markdown

Silo Kody — review complete

Review finished. Check the inline comments for findings and verify each suggestion against the code and tests.

Reviewing changes in Silo
  • Include the related issue, expected behavior, and validation steps in the PR description.
  • For API changes, describe the effect on Apple and Android clients and Jellyfin compatibility.
  • For plugin changes, identify the affected SDK contract, plugin, and catalog entry.
  • Follow this repository's AGENTS.md and CONTRIBUTING.md.
  • Request another review with @kody start-review in a PR comment.
  • React with 👍 or 👎 to give feedback on individual suggestions.
Review settings
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ✅
Security ✅
Business Logic ❌

@Brady3035

Copy link
Copy Markdown
Contributor Author

Fixed CI tests

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api-v2 API v2 / Huma migration program (epic #135); long-running, stacked by phase enhancement New feature or request go Pull requests that update go code impact: usability Core flow broken or severely blocked javascript Pull requests that update javascript code needs-review Needs maintainer review to resolve uncertain classification, scope, or changed evidence. priority: P2 Limited scope, workaround exists, or polish size/XXL 1000–2999 added + deleted lines (all files); change volume, not priority.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[bug] 4K entitlement creates 1080p and 2160p targets with force_dual_quality=false

2 participants