Skip to content

fix: count queued HLS transcodes - #58

Merged
tcconnally merged 1 commit into
mainfrom
fix/transcode-prefetch-accounting
Aug 5, 2026
Merged

fix: count queued HLS transcodes#58
tcconnally merged 1 commit into
mainfrom
fix/transcode-prefetch-accounting

Conversation

@tcconnally

Copy link
Copy Markdown
Owner

Corrective follow-up

This PR corrects the transcode-prefetch accounting from #57.

The prior implementation counted active HLS streams but excluded queued HLS playlist entries. Because mpv can open a queued prefetch demuxer before playback, multiple pending HLS transcodes could still exceed MAX_CONCURRENT_TRANSCODES.

This change:

  • counts current and queued HLS loads together;
  • applies that count before choosing a transcoded prefetch URL;
  • preserves the target cell's queued state during filter changes until mpv replaces the playlist;
  • adds regressions proving pending HLS loads consume the budget and that the wall accounting includes them.

Verification

  • Reliability tests: 54 passed.
  • macOS playback contract tests: 3 passed.
  • Playlist tests: 10 passed.
  • Full tests/run_all.py: all suites green.
  • compileall and git diff --check: passed.
  • Independent exact-tree review: passed; prior blocker reproduced and covered by the new tests.

Native macOS/Emby soak remains the target-host acceptance test after pulling the merged result.

@tcconnally
tcconnally merged commit 64b357d into main Aug 5, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant