From: Sergey M․ Date: Mon, 11 Feb 2019 17:13:50 +0000 (+0700) Subject: [twitch] Add new source format detection approach (closes #19193) X-Git-Url: http://git.oshgnacknak.de/?a=commitdiff_plain;h=985637cbbfc1a79091eb2f5ca4afec84f6616c75;p=youtube-dl [twitch] Add new source format detection approach (closes #19193) --- diff --git a/youtube_dl/extractor/twitch.py b/youtube_dl/extractor/twitch.py index 401615683..8c87f6dd3 100644 --- a/youtube_dl/extractor/twitch.py +++ b/youtube_dl/extractor/twitch.py @@ -136,7 +136,12 @@ class TwitchBaseIE(InfoExtractor): source = next(f for f in formats if f['format_id'] == 'Source') source['preference'] = 10 except StopIteration: - pass # No Source stream present + for f in formats: + if '/chunked/' in f['url']: + f.update({ + 'source_preference': 10, + 'format_note': 'Source', + }) self._sort_formats(formats)