Skip to content

Conversation

@bastimeyer
Copy link
Member

@bastimeyer bastimeyer commented Oct 7, 2023

#5498

This PR currently includes the commits of #5593. I will rebase and remove those commits once #5593 got merged into master.

As explained in #5498, all segmented streams should operate on segments which inherit from a common base segment. This base segment should define common attributes like uri, num and duration. The goal is to be able to have logic for a max stream duration and a stream start offset in the segmented stream base classes instead of having to implement this in each individual stream type separately.

  1. Rename segment classes of the various segmented streams, so there are no duplicates
  2. Rename and update the attributes of the DASHSegment, so they align with the base Segment
    Since the HLS spec (RFC 8216) defines segment sources as URIs (superset of URLs) because data can be retrieved from literally anywhere, I used that terminology.
  3. Finally add the base Segment and make segment dataclasses of each segmented stream implementation inherit from it
  4. Move HLSSegment and DASHSegment into dedicated modules as well

@bastimeyer bastimeyer force-pushed the stream/base-segment branch from 629ee42 to 4046a64 Compare October 8, 2023 12:54
@bastimeyer bastimeyer marked this pull request as ready for review October 8, 2023 12:54
@bastimeyer bastimeyer merged commit 32e4ff6 into streamlink:master Oct 8, 2023
@bastimeyer bastimeyer deleted the stream/base-segment branch October 8, 2023 13:01
snorkelopstesting2-coder pushed a commit to snorkel-marlin-repos/streamlink_streamlink_pr_5594_29ead82f-8877-4b93-ad99-103312137a5c that referenced this pull request Oct 22, 2025
snorkelopstesting3-bot added a commit to snorkel-marlin-repos/streamlink_streamlink_pr_5594_29ead82f-8877-4b93-ad99-103312137a5c that referenced this pull request Oct 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant