dash gen bug

This commit is contained in:
Brahim Hadriche committed 2025-09-21 19:26:04 -04:00
1 parent e029d24061
commit c12436f464
3 files changed
+14 -7

No files matched your search

+6
View File
@@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [Unreleased]
### Fixed
- Dash generation bug
## [0.41.20] - 2025-09-21
### Fixed
@@ -295,15 +295,15 @@ class DashManifest
for i = 0 to streams.Count() - 1
stream = streams[i]
if stream.type.startsWith("audio/")
if stream.bitrate = invalid
if StringUtils.IsNullOrEmpty(stream.bitrate)
LogWarn("Invalid audio stream bitrate, itag:", stream.itag)
continue for
end if
if stream.init = invalid
if StringUtils.IsNullOrEmpty(stream.init)
LogWarn("Invalid audio stream init, itag:", stream.itag)
continue for
end if
if stream.index = invalid
if StringUtils.IsNullOrEmpty(stream.index)
LogWarn("Invalid audio stream index, itag:", stream.itag)
continue for
end if
@@ -325,15 +325,15 @@ class DashManifest
stream = streams[i]
if stream.type.startsWith("video/")
if stream.bitrate = invalid
if StringUtils.IsNullOrEmpty(stream.bitrate)
LogWarn("Invalid video stream bitrate, itag:", stream.itag)
continue for
end if
if stream.init = invalid
if StringUtils.IsNullOrEmpty(stream.init)
LogWarn("Invalid video stream init, itag:", stream.itag)
continue for
end if
if stream.index = invalid
if StringUtils.IsNullOrEmpty(stream.index)
LogWarn("Invalid video stream index, itag:", stream.itag)
continue for
end if
@@ -101,7 +101,7 @@ namespace Innertube
hasLiveStreamingData = FormatsHaveLiveStreamingData(adaptiveFormats) or FormatsHaveLiveStreamingData(formats)
adaptiveFormats = TransformFormats(adaptiveFormats, not hasLiveStreamingData)
adaptiveFormats = TransformFormats(adaptiveFormats, not isLive and not hasLiveStreamingData)
formats = TransformFormats(formats, false)
parsedResponse["type"] = "video"
@@ -592,6 +592,7 @@ namespace Innertube
end if
for each fmt in formats
url = fmt["url"]
' TODO: source=yt_premiere_broadcast - is this considered live?
if IsString(url) and url.InStr("yt_live_broadcast") <> -1
return true
end if