Fix video preview playback #90

Merged
miro merged 1 commit from claude/video-preview-playback-9951ac into main 2026-10-12 19:40:33 +00:00
Owner

Video previews stalled after a few frames.

  • Browsers request Range: bytes=0-; the server answered with Content-Range: bytes 0-0/size (claiming 1 byte) and no Content-Type/Content-Length on 206 responses.
  • parseRange now handles bounded, open-ended and suffix ranges, clamps to the file size, and returns 416 when unsatisfiable. This also fixes shared-link playback.
  • The slideshow no longer says only images are supported when previewing a video.
Video previews stalled after a few frames. - Browsers request `Range: bytes=0-`; the server answered with `Content-Range: bytes 0-0/size` (claiming 1 byte) and no `Content-Type`/`Content-Length` on 206 responses. - `parseRange` now handles bounded, open-ended and suffix ranges, clamps to the file size, and returns 416 when unsatisfiable. This also fixes shared-link playback. - The slideshow no longer says only images are supported when previewing a video.
Fix video preview playback with correct range responses
All checks were successful
CI / lint (pull_request) Successful in 27s
CI / format (pull_request) Successful in 35s
CI / typecheck (pull_request) Successful in 39s
CI / test (pull_request) Successful in 40s
CI / knip (pull_request) Successful in 41s
CI / docker (arm64, docker-arm64) (pull_request) Successful in 13s
CI / build (pull_request) Successful in 39s
CI / docker (amd64, docker-amd64) (pull_request) Successful in 21s
CI / manifest (pull_request) Has been skipped
CI / deploy-test (pull_request) Has been skipped
E2E / playwright (pull_request) Successful in 1m46s
aeca6299b0
Open-ended Range requests produced a Content-Range of 0-0, and 206 responses lacked Content-Type and Content-Length, so browsers stalled after a few frames. Parse bounded, open-ended and suffix ranges against the file size and return 416 when unsatisfiable. Also stop the slideshow telling users videos can't be previewed.
miro merged commit 096687f229 into main 2026-10-12 19:40:33 +00:00
miro referenced this pull request from a commit 2026-10-12 19:40:34 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
miro/files!90
No description provided.