From ecb4f4ccd1ec94c6a41257d20e1b2ce9267a215d Mon Sep 17 00:00:00 2001 From: Cadence Ember Date: Mon, 13 Mar 2023 00:36:08 +1300 Subject: [PATCH] Change http_dash_fragments detection based on yt-dlp translating adaptive streams to fragments https://matrix.to/#/!vZmGzbsnHuVTLMItyg:cadence.moe/$VHp8D4XgW5jFbA6MhPaI52hZVMt_wpNy9gCSbF6Ot1Y?via=cadence.moe&via=matrix.org&via=envs.net --- extractors/video.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/extractors/video.py b/extractors/video.py index 68fc86a..58d68e6 100644 --- a/extractors/video.py +++ b/extractors/video.py @@ -105,6 +105,9 @@ def extract_video(id): "recommendedVideos": [] } + # result = info["formats"] + # return result + for format in info["formats"]: # Storyboard images are now included in formats, we don't want them. # Storyboards have neither audio nor video, so detect them that way. @@ -125,7 +128,7 @@ def extract_video(id): if is_adaptive: url = "" - if format["protocol"] == "http_dash_segments": + if "fragment_base_url" in format: # this is http dash, which is annoying and doesn't work in