You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(tvos): follow playback after Play/Pause resumes during a scrub - #994
Closes#993
Related issue: none (Android TV, Roku, and the web player are not affected)
Validation tasks: none
On Apple TV, resuming playback with Play/Pause after a pause can leave the scrubber stuck at the paused position. The video plays, but the bar and time label don't move until the player is reopened.
Select pauses playback and opens a timeline scrub at the paused position. While a scrub is open, the bar shows the scrub preview instead of the playhead. Play/Pause, Now Playing, SiloControl, the server remote, and watch party play all resume the engine without ending the scrub. When the controls then auto-hide, the scrubber is removed before its blur handler can end the scrub, so the stale preview comes back every time the controls do. #729 fixed the same symptom, but only when AI subtitles resume playback.
Approach
TVPlayerControls already cancels an open timeline scrub, without seeking, when isPlaying turns true during AI subtitles. This change drops the AI-subtitles condition, so any resume from outside the scrubber returns the bar to the playhead. The scrubber's own commit clears isTimelineScrubbing before it resumes playback, so a Select commit still seeks and plays as before.
Opening a timeline scrub also pauses a resume that is still landing its seek, and the scrub's own commit gives that resume back. Without this, pressing Select right after a commit-and-resume opened a scrub that the landing resume then cancelled.
Play/Pause during a scrub cancels the preview instead of seeking to it. That matches the #729 behavior and Android TV, where Play/Pause moves focus to the transport and hiding the controls clears any scrub (TvPlayerViewModel.kt:6389). Before this change, Play/Pause did not seek to the preview either.
AetherEngine and the app's time-tick filters were checked and are not involved: the engine keeps publishing its clock after a resume, and every filter clears itself. docs/tvos-player/04-tvos-controls-and-current-behavior.md now states the rule.
Validation
Build: the PR's Apple regression CI built the app and test bundles for Silo, SiloTV, and SiloMac at c16912c (** TEST BUILD SUCCEEDED **). The author has no Mac, so nothing was built locally.
Steps to check on Apple TV: play a video, click Select (playback pauses), press Play/Pause, wait about 5 seconds, then show the controls. The bar should follow playback. Also check that Select, Left or Right, then Select still seeks and resumes at the new position. Finally, check a quick reopen: Select, step, Select to commit, then Select again before playback resumes, step, and Select. Playback should seek to the second target and play.
Before (Apple TV, a build without this change, recorded with a phone): Select pauses at 5:28 and opens the scrub preview. After Play/Pause resumes, the video and subtitles move on, but the time stays at 5:28 / -2:36:33.
After: not captured yet. The author has no Mac to build this branch, so I've asked a maintainer below.
iPhone, iPhone Duo, iPad, and Mac are unaffected: TVPlayerControls and TVPlayerScrubber are compiled only for tvOS, and the iOS and macOS scrubbers end their scrub when the drag ends.
Risks
Unverified on device.
isResumePending reads viewerWantsToPlay (the play intent, unless an audio interruption holds it). A player left paused by an interruption that ended without .shouldResume is not a pending resume, so a scrub opened on it stays paused when committed (a8215cc).
If playback resumes on its own during a timeline scrub (for example, a watch party member presses Play), the local preview is dropped. The preview showed a paused position that no longer applied, so dropping it seems right.
Checklist
I read and can explain the complete diff.
This pull request addresses one concern.
The Evidence section shows every change a user can see, or says there is none.
AI Disclosure
Harness: Claude Code
Tool(s): Claude Code CLI
Model(s): claude-opus-5-5
Involvement: Fully AI-generated, not yet human verified. A person reported the frozen scrubber on Apple TV. The agent found the cause, wrote the change, and filed the issue.
Adversarial review: one reviewer agent and a separate verifier agent reviewed 0480748..62cd39d. They confirmed one finding: a scrub reopened while a commit's resume was still landing was cancelled when the resume landed. Fixed in 116b7b1.
Fix tvOS scrubber to follow playback when Play/Pause resumes during a scrub
Fixes the case where playback resumes from outside an open timeline scrub: the scrub now cancels without seeking, the bar returns to the playhead, and controls auto-hide resumes (TVPlayerControls.swift)
A timeline hold or Select now recognizes a pending resume as playback to pause. It records the viewer transport command count so the held resume is only restored if no newer viewer Play/Pause command superseded it (TVPlayerScrubber.swift)
Adds PlayerViewModel.isResumePending and viewerTransportCommandCount, and endScrub now routes a no-seek resume through the replacement transport when a seek replan or protocol-v3 replacement is in progress (PlayerViewModel.swift)
Behavioral Change: focus loss, session end, and cancel of a timeline scrub all go through the new shared dropTimelineScrub cleanup, which can restore a paused pending resume; watch-party playback is excluded from the pending-resume handling
On Apple TV, Select pauses and opens a timeline scrub at the paused
position. Resuming with Play/Pause, Now Playing, a remote, or a watch
party started playback but left the scrub open. The bar kept showing the
paused position, and the auto-hide removed the scrubber before its blur
could end the scrub, so it stayed stuck until the player was reopened.
Cancel an open timeline scrub without seeking whenever playback resumes.
The AI subtitles case from Silo-Server#729 already did this; it now covers every
resume.
ClosesSilo-Server#993
Co-Authored-By: Claude Opus 5.5 <[email protected]>
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 settingsReview Options
The following review options are enabled or disabled:
Options
Enabled
Bug
✅
Performance
✅
Security
✅
Business Logic
❌
⚠️ 3 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:
This review ran on the open-source allowance, not this organization's plan, because the pull request author doesn't have an assigned seat. Waiting won't change this — ask an organization admin to assign them a seat, or add seats in Billing if every seat is already assigned, then retry.
When playback resumes during an active tvOS timeline scrub, the controls cancel the scrub and clear its state. The player model now identifies pending playback intent, and timeline selection accounts for that state.
Changes: tvOS scrub cancellation
Layer / File(s)
Summary
Handle active and pending playback during scrubbing iosApp/iosApp/Screens/Player/PlayerViewModel.swift, iosApp/iosApp/Screens/Player/tvOS/TVPlayerScrubber.swift, iosApp/iosApp/Screens/Player/tvOS/TVPlayerControls.swift, docs/tvos-player/04-tvos-controls-and-current-behavior.md
PlayerViewModel exposes isResumePending and pauses for timeline selection when playback is active or pending. The scrubber records pending playback intent. When playback starts during a timeline scrub, the controls clear the scrub state and resume the auto-hide timer. The documentation and comment describe playback resuming from outside the scrubber.
On Apple TV, a scrub can unexpectedly resume paused playback or leave playback paused after cancellation. The pending-resume hold ordering also remains uncertain.
Security architecture risk: Low · up to 494cc
The change is confined to tvOS playback controls. Existing watch-party permission checks remain in place, and no new externally accessible command or privilege was identified. Some asynchronous playback and teardown behavior remains unverified.
Retained concerns
No architecture-level concerns identified.
Security review details
Security Blast Radius
inferred — The examined effects are local playback and scrub-preview state, plus transport requests to the current watch party under existing permissions. No expanded tenant, credential, infrastructure or arbitrary-service authority was identified in the changed flows.
Trust Boundaries and Controls
observed — The pause helper submits through the watch-party adapter before local transport. The adapter returns handled for denied or dropped room requests, preventing solo fallback. The room session also checks current adapter identity, connection, attachment and action permission before sending transport requests; seek permission remains host-scoped.
Resilience and Maintainability Implications
observed — Existing room-seek containment keeps submitted targets separate from the room position and restores the room snapshot after timeout. This limits stale optimistic timeline state when a request is refused or never answered; the PR does not change that recovery mechanism.
Pre-merge checks: 4 · 1
Failed checks: 1 inconclusive
Check name
Status
Explanation
Resolution
Docstring Coverage
Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documenta…
Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed checks: 4 passed
Check name
Status
Explanation
Title check
The title clearly identifies the tvOS scrubber fix when Play/Pause resumes playback during a scrub.
Description check
The description directly explains the scrubber issue, implementation, validation, risks, and affected platforms.
Linked Issues check
Directly linked issue #993 requires the tvOS scrubber and time label to follow playback after playback resumes during an open timeline scrub. The whole-PR diff (c9fb59b..494cc67) meets this requiremen…
Out of Scope Changes check
All whole-PR changes relate to #993 and its reproduction path:
- TVPlayerControls.swift: removes the AI-subtitles-only condition from the scrub-cancel-on-playback handler and re-arms auto-hide. This …
Full details: Linked Issues check
Explanation
Directly linked issue #993 requires the tvOS scrubber and time label to follow playback after playback resumes during an open timeline scrub. The whole-PR diff (c9fb59b..494cc67) meets this requirement in code:
TVPlayerControls.swift: the viewModel.isPlaying change handler no longer requires viewModel.subtitleAI.livePresentationActive. When playback starts while a timeline scrub is open, it calls cancelScrub() without seeking, clears isTimelineScrubbing and resumePlaybackAfterTimelineSelection, and calls resumeAutoHide(). This covers Play/Pause, which the issue names as the trigger.
PlayerViewModel.swift: isResumePending (!isPlaying && viewerWantsToPlay) lets pauseForTimelineSelection() pause a resume that is still landing. This supports a quick reopen, which the adversarial review found could otherwise be cancelled by the landing resume.
The Select commit path clears isTimelineScrubbing before it resumes, so a commit still seeks and plays, as the PR states.
Issue #993 has no automated-test acceptance criterion, so the absence of added tests does not cause a failure. Device validation was not run, and the after-evidence is not captured. This is an unverified behavior, not a coding requirement failure. The watch-party ordering race noted in the PR thread leaves playback paused with the scrub closed. That state matches the paused playhead and does not contradict #993.
Full details: Out of Scope Changes check
Explanation
All whole-PR changes relate to #993 and its reproduction path:
TVPlayerControls.swift: removes the AI-subtitles-only condition from the scrub-cancel-on-playback handler and re-arms auto-hide. This is the core fix for #993.
TVPlayerScrubber.swift: beginTimelineHoldIfNeeded and the Select path record resume intent when a resume is pending, and pause that resume before the scrub opens. This prevents a new scrub from being cancelled by a landing resume. This directly relates to the quick-reopen case of the same symptom.
PlayerViewModel.swift: isResumePending and the widened pauseForTimelineSelection() condition. These support the pending-resume handling above. The change is tvOS-only (#if os(tvOS) block in the same region).
docs/tvos-player/04-tvos-controls-and-current-behavior.md: documents the new resume rule for the changed behavior. This is a legitimate supporting change.
No unrelated product area, platform, or public API change is present. The raw summary lists no changes to exported declarations beyond the internal isResumePending property. The PR description states that iOS and macOS are unaffected because the changed types are tvOS-only. I confirmed this only from the diff hunks for TVPlayerControls.swift and PlayerViewModel.swift.
Full details: Docstring Coverage
Explanation
Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 2 functions across 2 files. (1 skipped: 1 too large.)
Resolution
Write docstrings for the functions missing them to satisfy the coverage threshold.
Finishing Touches
Generate unit tests (beta)
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
The Apple TV scrubber now drops its preview and follows the live playhead when playback resumes during a scrub (iosApp/iosApp/Screens/Player/tvOS/TVPlayerControls.swift); Apple TV evidence is missing. Please add before-and-after captures of the same playback screen and a short recording of the resume sequence, identifying the device and build or commit.
Automated check: Macroscope check run agent (gpt-6-luna). Evidence was not reviewed for correctness.
Valid. This PR changes what the Apple TV scrubber shows after a resume, so it needs a tvOS before-and-after recording. The author can't run Apple builds, so we've asked them for a device capture of the resume sequence in the PR body's Validation section, identified by device and commit. It will go under the Evidence heading before merge.
Select right after a timeline commit that resumes playback, while its
seek is still landing, opened a new scrub without pausing: playback was
not running yet, so the pause was skipped. When the resume landed, the
new resume handler cancelled that scrub and dropped its target.
Opening a timeline scrub now pauses a resume that is still pending and
gives it back on the scrub's own commit.
Refs Silo-Server#993
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Finding: Pause, Select, step Right, then Select to commit. The commit seeks and resumes. While that seek is still landing, isPlaying is still false. Pressing Select again opens a new timeline scrub, but pauseForTimelineSelection skips the pause because isPlaying is false, so the earlier resume stays pending. When it lands, isPlaying turns true, and the widened resume handler cancels the new scrub. The viewer's second target is dropped without a seek.
Verification: Confirmed. Traced endScrub → commitSeek / handleNowPlayingPlay → AetherPlaybackController.play(). isPlaying turns true only on the engine's .playing (PlayerViewModel.swift:1882), which waits for the seek to land. Select on the scrubber (TVPlayerScrubber.swift:107-109) and beginScrub accept input in that window.
Resolution: Fixed in 116b7b1: opening a timeline scrub now pauses a resume that is still pending (isResumePending: not playing, but the controller's shouldPlayWhenReady is still set) and sets resumePlaybackAfterTimelineSelection. The new scrub opens on a paused player, and its own commit resumes playback at the viewer's new target.
A timeline scrub pins the controls. A watch party or server remote play
does not re-arm their auto-hide, so after the resume cancelled the scrub
the controls stayed over the video until the viewer dismissed them.
Refs Silo-Server#993
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The latest commit adds another Apple TV-visible case: reopening a timeline scrub while the previous commit's resume seek is still landing now keeps the scrub active and returns playback on commit. The Evidence section still has no captures; please add a before-and-after player capture and a short recording of this immediate reopen-and-commit sequence, identifying the Apple TV device and build or commit.
Automated check: Macroscope check run agent (gpt-6-luna). Evidence was not reviewed for correctness.
Valid. The device recording will also cover reopening a scrub right away: Select, step, Select to commit, then Select again before playback resumes, step, and Select. It should seek to the second target and play. I added that sequence to the evidence request.
Play a video and click Select. Playback pauses and the scrub preview opens.
Press Play/Pause, wait about 5 seconds, then show the controls. The time and bar should follow playback; before this change they stayed at the paused position.
Quick reopen: Select, step Left or Right, Select to commit, then Select again before playback resumes, step, and Select. Playback should seek to the second target and play.
A short recording of steps 1–2 on the same kind of screen would cover the Evidence section. Thanks!
The reason will be displayed to describe this comment to others. Learn more.
🤖 Claude Code (claude-opus-5-5)
One finding, which I'm fixing in a commit on this branch, so there's no need to change it yourself. The approach holds up: the timeline commit clears isTimelineScrubbing before it resumes playback, and isPlaying turns true only on the engine's .playing state, so a seek or load in flight doesn't cancel a scrub. A Codex (gpt-6.1-sol) cross-check reviewed this head too; the finding below is one of its results that I confirmed in the source.
An audio interruption that ends without .shouldResume keeps the play
intent but leaves the player paused. isResumePending treated that as a
resume still landing, so a scrub opened on the paused player resumed
playback when committed. Use viewerWantsToPlay, which excludes an
interrupted session.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Review summary for 8b8a8104 (main merged in for #1022). The fix is sound and conditionally ready. It still needs to be seen working on an Apple TV.
Addressed
An interrupted, paused player counted as a pending resume, so committing a scrub opened on it started playback. Fixed in a8215cc: isResumePending now uses viewerWantsToPlay.
Holding Left or Right right after a commit opened a scrub without pausing, and the commit's landing resume then cancelled it mid-hold (CodeRabbit, outside the diff). Fixed in 6c6e11c: the hold path holds a pending resume and gives it back on commit, as Select does. 27cc5d0 limits that to a scrub that can open, so a watch-party member who can't seek never pauses the room (Kody).
After the merge, Codex found two more cases, both fixed in 1c14eac: a Pause held for a fresh load was read as a pending resume, and a scrub reopened during a reanchor and closed without moving started the outgoing stream at its old position. CodeRabbit then found that cancelling a hold that paused a landing resume left playback paused; fixed in 481c7ea. Codex then found that a subtitle report was treated as a replacement and that a newer Pause during such a hold was overridden; both fixed in 560343c. Kody then found that in a watch party such a hold paused the whole room and room commands bypassed that check; 8b8a810 leaves holds in a party as they are on main.
Left for the maintainers
A scrub commit that needs a Protocol V3 seek_reanchor loads paused instead of resuming. main has the same behavior for an ordinary Select during playback. Fixed on main by fix(tvos): resume playback after a scrub commit that reanchors the stream #1022, now merged into this branch. During that replan, isResumePending treats the paused replacement under a recorded Play as a resume still landing, so a new scrub pauses it and resumes on commit.
In a watch party, a room Play already scheduled to run can arrive just after Select sends the room a pause. That Play closes the new scrub, and the pause then leaves playback paused. The viewer loses a preview they have barely moved and presses Select again. Fixing this would need command ordering in WatchPartySession, which is more than this PR should carry. I'm not changing it here.
No after capture yet. Device check from the PR body: Select, Play/Pause, wait 5 s, show the controls, and the bar follows playback.
Checks
Approach: the commit path clears isTimelineScrubbing before it resumes playback, and isPlaying only turns true on the engine's .playing state, so a seek or load in flight doesn't cancel a scrub.
Cross-check: Codex (gpt-6.1-sol) reviewed c16912c and found two issues: the interruption case above (fixed) and the watch-party ordering race (not fixed).
Build: SiloTV built at 8b8a810 on the Mac build service. Not run on a simulator or device.
Validated features: the PR names no validation tasks. I did not check the v1.0 board.
User manual: no siloserver.org page covers Play/Pause during a tvOS scrub. Manual unaffected.
Android parity: Android TV already drops a scrub when the controls hide, as the PR body notes. No Android change needed.
Evidence: the published page has the before capture only. Neither fix commit changes what that capture shows.
Fit: 9/10 · Readiness: 7/10 — conditional (assuming CI is green)
Fit: this fixes a visible playback bug in the tvOS player, follows the existing AI-subtitles rule instead of adding a new path, and matches Android TV.
Readiness: the code holds up under review, but nothing has shown it working yet: no device run, and no test that fails on main.
The reason will be displayed to describe this comment to others. Learn more.
An interruption can resume playback and cancel an active scrub
A pending .shouldResume can restart playback and cause the isPlaying observer to discard an active scrub. Update pauseForTimelineSelection to disarm automatic resume during an interruption while keeping the saved scrub resume intent false.
Prompt for LLM
File iosApp/iosApp/Screens/Player/PlayerViewModel.swift, line 7095:
An interruption can resume playback and cancel an active scrub
If a viewer opens a timeline scrub during an audio interruption that later ends with `.shouldResume`, this predicate prevents `pauseForTimelineSelection` from clearing the pending play intent, so the engine resumes and the `isPlaying` observer discards the active scrub. Disarm automatic transport resume when opening a scrub during an active interruption, while keeping the saved scrub resume intent false.
The reason will be displayed to describe this comment to others. Learn more.
🤖 Claude Code (claude-opus-5-5)
No change. A scrub opened during an interruption is on a paused player, and if the interruption then ends with .shouldResume, playback resumes from outside the scrubber. This PR treats that like any other outside resume: it drops the preview so the bar follows the video, as the new line in docs/tvos-player/04-tvos-controls-and-current-behavior.md states. Disarming the system resume while the scrub is open would change interruption behavior for viewers who expect playback to come back after a call, which is outside this fix.
The reason will be displayed to describe this comment to others. Learn more.
That reasoning is sound. If the intended rule is to cancel an active preview whenever playback resumes from outside the scrubber, an interruption ending with .shouldResume fits that rule. I’d withdraw the suggestion to disarm the automatic resume.
It would still be useful to test that sequence on tvOS: open a scrub during an interruption, end the interruption with .shouldResume, and verify that playback resumes and the preview is cleared. The behavior remains unverified on a device or simulator.
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to GitHub limitations.
⚠️ Outside diff range comments (1)
Major · Handle a pending resume when a hold opens the scrub. · TVPlayerScrubber.swift:349
iosApp/iosApp/Screens/Player/tvOS/TVPlayerScrubber.swift:349 Major · Functional Correctness · Quick win
Handle a pending resume when a hold opens the scrub.
When isResumePending is true, retain it for the new scrub and pause the pending resume before calling beginScrub. Preserve the current behavior for an already playing player.
Suggested fix
- resumePlaybackAfterTimelineSelection = viewModel.isPlaying+ let pendingResume = viewModel.isResumePending+ resumePlaybackAfterTimelineSelection = viewModel.isPlaying || pendingResume+ if pendingResume {+ viewModel.pauseForTimelineSelection()+ }
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: 749a57ba-758f-4627-a951-979baaa23262
Commits
Reviewing files that changed from the base of the PR and between 62cd39d and a8215cc.
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.
Holding Left or Right opens a timeline scrub without pausing. If a
commit's resume was still landing its seek, the resume then cancelled
that scrub mid-hold. Pause the pending resume and give it back on
commit, as Select already does.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
A watch party member who can't seek gets no scrub from beginScrub, so
pausing a landing resume for that hold paused the room with no commit
to resume it. Only hold the resume when the scrub can open.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
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 settingsReview Options
The following review options are enabled or disabled:
Options
Enabled
Bug
✅
Performance
✅
Security
✅
Business Logic
❌
⚠️ 3 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:
The reason will be displayed to describe this comment to others. Learn more.
Add the required after-change Apple TV recording
For this visible tvOS timing change, the reviewed commit's Evidence section provides only a before recording and explicitly says the after capture has not been made. AGENTS.md requires “before-and-after captures of the same screen with the same data” plus a short recording when timing or focus matters, so the supplied evidence does not meet that gate. Attach an Apple TV after recording demonstrating Play/Pause resume and the rapid-reopen flow before merging.
The reason will be displayed to describe this comment to others. Learn more.
🤖 Claude Code (claude-opus-5-5)
Agreed that the after capture is still missing. The maintainers are arranging the Apple TV recording; I'll add it to the evidence page when it exists. Leaving this thread open until then.
…scrub
A Pause held for a fresh load lives in freshLoadPlayIntent, so
isResumePending read the outgoing controller's stale Play and a no-move
scrub commit started the replacement. Read the held intent first.
A scrub reopened while a reanchor replaces the transport, then closed
without moving, called play() on the outgoing transport and ran the old
stream at its pre-seek position. Record the Play for the replacement
instead, as the reanchor itself does.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.
A hold opened while a resume was still landing pauses it so the resume
can't cancel the hold. Menu or blur then left playback paused, though a
hold over playback otherwise keeps it running. Resume without seeking
when that hold ends without a commit.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
… newer Pauses
A subtitle report keeps the running stream, so deferring a reopened
scrub's Play to a replacement that never comes left video paused. Defer
only while a seek replan or a Protocol V3 replacement is in flight.
A Pause from Now Playing or SiloControl during a hold that paused a
landing resume was overridden when the hold was cancelled. Give the
resume back only when no newer Play or Pause came after the hold.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Holding a pending resume from a Left/Right hold paused the whole room,
and room Play and Pause requests bypass the viewer command count, so a
newer room Pause could be overridden when the hold was cancelled. In a
watch party a hold now leaves playback alone, as it does on main.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
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 settingsReview Options
The following review options are enabled or disabled:
Options
Enabled
Bug
✅
Performance
✅
Security
✅
Business Logic
❌
⚠️ 3 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:
The reason will be displayed to describe this comment to others. Learn more.
A pending watch-party resume cancels an active arrow scrub
Revises an earlier Kody suggestion on iosApp/iosApp/Screens/Player/tvOS/TVPlayerScrubber.swift:352 (2026-11-05 18:41 UTC).
Preserve the scrub across the pending resume without sending a room-wide pause.
Prompt for LLM
File iosApp/iosApp/Screens/Player/tvOS/TVPlayerScrubber.swift, lines 359-360:
**Revises an earlier Kody suggestion** on `iosApp/iosApp/Screens/Player/tvOS/TVPlayerScrubber.swift:352` (2026-11-05 18:41 UTC).
A pending watch-party resume cancels an active arrow scrub
A pending resume is no longer held during a watch-party arrow scrub, so the landing resume can cancel the active scrub, as described by the adjacent comment. Preserve the scrub across the pending resume without sending a room-wide pause.
The reason will be displayed to describe this comment to others. Learn more.
🤖 Claude Code (claude-opus-5-5)
Correct, and it is the trade-off 8b8a810 made: in a watch party, a hold opened just as a room resume is landing is closed when it lands, because holding it would need a room-wide Pause. This is the same class as the room-ordering case in the summary, where a room Play closes a scrub that a member just opened. Keeping the scrub open would mean exempting hold scrubs from the rule that an outside resume ends the scrub, which this PR relies on elsewhere. Leaving this open as a maintainer decision with that case.
The reason will be displayed to describe this comment to others. Learn more.
That trade-off makes sense. The watch-party case is a real limitation, but avoiding a room-wide pause and keeping the rule that an outside resume ends a scrub are reasonable choices.
I’d leave this as a maintainer decision, with the quick-reopen watch-party case explicitly documented and included in device validation. If maintainers accept the behavior, this suggestion does not need to block the PR.
The reason will be displayed to describe this comment to others. Learn more.
Resume local seeks instead of waiting for a replacement
On tvOS, if a debounced Left/Right skip is still awaiting a local seek, opening a Select scrub and closing it without moving can now leave playback paused. seekReplanTask also wraps ordinary local engine.seek calls, so this branch records Play without starting the engine. However, commitSeek's .completed path only calls play() when the original requestedPaused == false; debounced skips pass nil, so nothing consumes the restored intent and no replacement loads to apply it. Restrict this deferral to actual transport replacements, or consume the deferred resume when a local seek completes.
The reason will be displayed to describe this comment to others. Learn more.
Respect server-realtime Pause when cancelling a held resume
During solo tvOS playback, if a server/admin Pause arrives after a Left/Right hold has paused a pending resume, cancelling the hold with Menu overrides that newer Pause. The additional evidence beyond the Now Playing/SiloControl fix is the solo .pause arm in handleRealtimeCommand (PlayerViewModel.swift:9567–9568): it directly pauses the controller without advancing viewerTransportCommandCount. This equality check therefore still passes, and cancellation issues Play or re-arms replacement autoplay. Include server-realtime transport commands in the generation used to decide whether the held resume remains valid.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bugSomething isn't workingimpact: polishAnnoyance, cosmetic, or nice-to-havepriority: P2Limited scope, workaround exists, or polishsize/M50–199 added + deleted lines (all files); change volume, not priority.
2 participants
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Closes #993
Related issue: none (Android TV, Roku, and the web player are not affected)
Validation tasks: none
On Apple TV, resuming playback with Play/Pause after a pause can leave the scrubber stuck at the paused position. The video plays, but the bar and time label don't move until the player is reopened.
Select pauses playback and opens a timeline scrub at the paused position. While a scrub is open, the bar shows the scrub preview instead of the playhead. Play/Pause, Now Playing, SiloControl, the server remote, and watch party play all resume the engine without ending the scrub. When the controls then auto-hide, the scrubber is removed before its blur handler can end the scrub, so the stale preview comes back every time the controls do. #729 fixed the same symptom, but only when AI subtitles resume playback.
Approach
TVPlayerControlsalready cancels an open timeline scrub, without seeking, whenisPlayingturns true during AI subtitles. This change drops the AI-subtitles condition, so any resume from outside the scrubber returns the bar to the playhead. The scrubber's own commit clearsisTimelineScrubbingbefore it resumes playback, so a Select commit still seeks and plays as before.Opening a timeline scrub also pauses a resume that is still landing its seek, and the scrub's own commit gives that resume back. Without this, pressing Select right after a commit-and-resume opened a scrub that the landing resume then cancelled.
Play/Pause during a scrub cancels the preview instead of seeking to it. That matches the #729 behavior and Android TV, where Play/Pause moves focus to the transport and hiding the controls clears any scrub (
TvPlayerViewModel.kt:6389). Before this change, Play/Pause did not seek to the preview either.AetherEngine and the app's time-tick filters were checked and are not involved: the engine keeps publishing its clock after a resume, and every filter clears itself.
docs/tvos-player/04-tvos-controls-and-current-behavior.mdnow states the rule.Validation
Apple regressionCI built the app and test bundles forSilo,SiloTV, andSiloMacat c16912c (** TEST BUILD SUCCEEDED **). The author has no Mac, so nothing was built locally.SiloMacpassed.SiloandSiloTVeach failed one test,CalendarTimeZoneTests.testLoadAfterATimeZoneChangeRequestsTheSameWeekInTheNewZone("2026-11-03 03:56:44 +0000"is not equal to"2026-11-02 08:00:00 +0000"). This change does not cause that failure: the test fails on any branch during the week of 2 November 2026. It is tracked in [bug] CalendarTimeZoneTests fails while its hard-coded week is the current week #989 and fixed in test(calendar): pin the timezone-change test to a past week #990.Steps to check on Apple TV: play a video, click Select (playback pauses), press Play/Pause, wait about 5 seconds, then show the controls. The bar should follow playback. Also check that Select, Left or Right, then Select still seeks and resumes at the new position. Finally, check a quick reopen: Select, step, Select to commit, then Select again before playback resumes, step, and Select. Playback should seek to the second target and play.
Evidence
Evidence: https://evidence.siloserver.org/r/silo-apple/pr-994/
iPhone, iPhone Duo, iPad, and Mac are unaffected:
TVPlayerControlsandTVPlayerScrubberare compiled only for tvOS, and the iOS and macOS scrubbers end their scrub when the drag ends.Risks
isResumePendingreadsviewerWantsToPlay(the play intent, unless an audio interruption holds it). A player left paused by an interruption that ended without.shouldResumeis not a pending resume, so a scrub opened on it stays paused when committed (a8215cc).Checklist
AI Disclosure
claude-opus-5-50480748..62cd39d. They confirmed one finding: a scrub reopened while a commit's resume was still landing was cancelled when the resume landed. Fixed in 116b7b1.🤖 Generated with Claude Code
Note
Fix tvOS scrubber to follow playback when Play/Pause resumes during a scrub
PlayerViewModel.isResumePendingandviewerTransportCommandCount, andendScrubnow routes a no-seek resume through the replacement transport when a seek replan or protocol-v3 replacement is in progress (PlayerViewModel.swift)dropTimelineScrubcleanup, which can restore a paused pending resume; watch-party playback is excluded from the pending-resume handlingMacroscope summarized 8b8a810.