Repository navigation
fix(android): play gzip-compressed HLS playlists in mpv again - #562
Merged
Merged
Conversation
Drop FFmpeg's reconnect_streamed from the shared mpv options used by the Android phone and TV, as #559 did for Apple. With it, FFmpeg treats the normal end of a response of unknown length (a gzip-compressed playlist) as a dropped connection, re-requests past the end and fails to parse the playlist, so only the audio played. The other reconnect options stay. Also corrects the Apple TV redesign checks doc, which still listed the option after #559. Co-Authored-By: Claude Opus 5.5 <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.
Same fix as #559 (iPhone and Apple TV), for the Android phone and Android TV.
Problem
Some sites serve their HLS playlists gzip-compressed, so the response has no usable length. With FFmpeg's
reconnect_streamed=1, the normal end of such a response is treated as a dropped connection: FFmpeg re-requests past the end (Will reconnect at <full size> … End of file), the variant playlists fail to parse (hls: parse_playlist error Invalid data), and only the audio rendition plays: a blank picture shown as live (not seekable, growing duration). Diagnosed on the iPhone; Android's mpv uses the same option.Change
shared/.../MpvLavfReconnectOptions.kt: dropreconnect_streamed=1.reconnect=1, retries on network errors and HTTP 429/5xx, and the retry caps stay. Used by bothMpvPlayerEngines (phone and TV) forstream-lavf-oanddemuxer-lavf-o.tv/apple/docs/redesign-checks.md: the option string still listedreconnect_streamed=1after fix(apple): play gzip-compressed HLS playlists in mpv again #559; corrected.Testing
./gradlew :shared:testAndroidHostTest --tests 'com.playbridge.shared.player.MpvLavfReconnectOptionsTest'passes from bothmobile/androidandtv/android.🤖 Generated with Claude Code