fix(llhls): watcher causes playback failure #1398
Merged
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.
Description
Low latency streams can get into a bad state on startup and fail if the seek position is adjusted with the playback watcher, specifically by
fixesBadSeeks
. There are checks in that function that determine if a seek position is outside the seekable window. This seekable range is a calculated interval duration from the playlist, where the end of the seekable window is theduration - HOLD-BACK
. When the player first calculates the seekable range from the manifest, the interval duration returned is not precise. Sometimes this non-precise duration will be greater than the precise duration determined after the playlist is loaded. Since the player uses the first, non-precise duration calculation to determine the start position of a live asset, if the precise duration is updated to a lesser value before the player completes the seek to the start position this can cause the start position to fall outside of the "safe seek window". When combined with a manifest that utilizes #EXT-X-INDEPENDENT-SEGMENTS tags, this would cause the player to get stuck requesting the same partial segment in rapid succession, triggering playlist exclusion logic and eventual a fatalMEDIA_ERR_DECODE
.The PRs for #EXT-X-INDEPENDENT-SEGMENTS support are:
videojs/m3u8-parser#165
and
#1399
Specific Changes proposed
Adding an exclusion for LLHLS to allow for seeking beyond the "safe" seek window.
Requirements Checklist