Lokasi ngalangkungan proxy:   [ UP ]  
[Ngawartoskeun bug]   [Panyetelan cookie]                
Skip to content

Count DASH segments from the SegmentTimeline as the standard defines - #421

Open
niraami wants to merge 1 commit into
EbbLabs:mainfrom
niraami:fix/dash-segment-count
Open

niraami wants to merge 1 commit into
EbbLabs:mainfrom
niraami:fix/dash-segment-count

Conversation

@niraami

@niraami niraami commented Nov 16, 2026

Copy link
Copy Markdown

Fixes #420

Each S element is one segment followed by r repeats, so a timeline holds sum(r + 1) segments. get_urls counted 2 + sum(r or 1), which only matches when exactly one S element repeats. A short track whose timeline has no repeat (e.g. track 534096006) got a URL for a segment that does not exist, which TIDAL answers with 400 Bad Request; a timeline with two repeated elements lost a segment.

The URLs now start with the template's initialization URL and number the media segments from startNumber (default 1).

Each S element is one segment followed by r repeats, so a timeline holds
sum(r + 1) segments. get_urls counted 2 + sum(r or 1), which only matches
when exactly one S element repeats. A short track whose timeline has no
repeat (e.g. track 534096006) got a URL for a segment that does not exist,
which TIDAL answers with 400 Bad Request; a timeline with two repeated
elements lost a segment.

The URLs now start with the template's initialization URL and number the
media segments from startNumber (default 1).
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.

Short tracks request a segment that does not exist (400 Bad Request)

1 participant