Repository navigation
fix(preview): drop seeking-guard that froze playback in all 3 previews< 8000 /span> - #44
Merged
Merged
Conversation
#43 added a defensive `if (videoEl.seeking) return` guard to the sync effects in both CamPreview surfaces. Intent was to avoid stacking currentTime writes during the 100-400 ms decoder warmup. In practice it broke responsive scrubbing and froze Arrange playback: - Triage: continuous scrubs / loop-wraps land during the previous seek's warmup → guard skips → user sees stale frames jump-cut to catch up = visible "ruckeln". - Arrange: initial play() seeks; while seeking the guard skips every subsequent tick, including the `if (isPlaying && videoEl.paused) play()` recovery path. Browser's seek-implicit pause is never re-played → video frozen. The jump-vs-natural classifier already prevents the original stutter loop (natural advance with a generous 500 ms threshold; only jumps trigger seeks). The seeking-guard was redundant and harmful — browsers handle "newer setCurrentTime supersedes in-flight seek" internally. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Same bug as Triage+Arrange (3f21766) — the pool's syncSlot had its own `if (v.seeking) return` that suppressed the play() recovery while the browser had implicitly paused the element during a seek. Result: editor preview videos froze on the first seek. The jump-vs-natural classifier already prevents the original stutter loop. Browsers handle a fresh currentTime write supersession during an in-flight seek internally — we don't need the guard. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
#43 added a defensive `if (videoEl.seeking) return` guard to the sync logic in all three preview surfaces (Triage, Arrange, editor compositor pool). Intent was to avoid stacking `currentTime` writes during the 100-400 ms decoder warmup. In practice it broke playback in all of them:
Visible symptoms after #43 landed in main:
The jump-vs-natural classifier in #43 already prevents the original stutter loop (natural advance only seeks at >500 ms drift; jumps seek at >50 ms). The seeking-guard was redundant and harmful — browsers handle "newer setCurrentTime supersedes in-flight seek" internally.
Test plan
🤖 Generated with Claude Code