stream.hls: cache parsed multivariant playlist#4568
Merged
gravyboat merged 1 commit intoJun 4, 2022
Conversation
- Move `M3U8Parser.base_uri` to `M3U8.uri`
- Add `multivariant` to `{,Muxed}HLSStream` and deprecate `url_master`:
- Set `multivariant` in `HLSStream.parse_variant_playlist` instead of
`url_master`, so that stream instances can keep a reference of
their parsed multivariant playlist.
This is required for implementing the `EXT-X-SESSION-{DATA,KEY}`
HLS tags, or for accessing custom tags in HLS subclasses.
- Update `to_manifest_url`
TODO: rename method / refactor interface
- Fix subclasses in various plugins
Member
|
Nice job getting ahead of this! The naming makes sense to me. |
Billy2011
added a commit
to Billy2011/streamlink-27
that referenced
this pull request
Jun 7, 2022
- Move `M3U8Parser.base_uri` to `M3U8.uri`
- Add `multivariant` to `{,Muxed}HLSStream` and deprecate `url_master`:
- Set `multivariant` in `HLSStream.parse_variant_playlist` instead of
`url_master`, so that stream instances can keep a reference of
their parsed multivariant playlist.
This is required for implementing the `EXT-X-SESSION-{DATA,KEY}`
HLS tags, or for accessing custom tags in HLS subclasses.
- Update `to_manifest_url`
TODO: rename method / refactor interface
- Fix subclasses in various plugins
Billy2011
added a commit
to Billy2011/streamlink-27
that referenced
this pull request
Jun 7, 2022
- Move `M3U8Parser.base_uri` to `M3U8.uri`
- Add `multivariant` to `{,Muxed}HLSStream` and deprecate `url_master`:
- Set `multivariant` in `HLSStream.parse_variant_playlist` instead of
`url_master`, so that stream instances can keep a reference of
their parsed multivariant playlist.
This is required for implementing the `EXT-X-SESSION-{DATA,KEY}`
HLS tags, or for accessing custom tags in HLS subclasses.
- Update `to_manifest_url`
TODO: rename method / refactor interface
- Fix subclasses in various plugins
This was referenced Jul 6, 2022
Merged
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.
M3U8Parser.base_uritoM3U8.urimultivariantto{,Muxed}HLSStreamand deprecateurl_master:multivariantinHLSStream.parse_variant_playlistinstead ofurl_master, so that stream instances can keep a reference oftheir parsed multivariant playlist.
This is required for implementing the
EXT-X-SESSION-{DATA,KEY}HLS tags, or for accessing custom tags in HLS subclasses.
to_manifest_urlTODO: rename method / refactor interface
The
url_masterparameter was not removed from{,Muxed}HLSStreamfor backwards compatibility reasons. This can be done later when other HLS method signatures get changed in the future.Instead of "master", I chose the name "multivariant", because that's how master playlists will be called in future versions of the HLS spec. This avoids one unnecessary parameter name change later on and keeps it consistent with future spec implementations.