From 831695a576c6a5cb37a235c382b796cdf35c44de Mon Sep 17 00:00:00 2001 From: Robert Jacobson Date: Sat, 21 Mar 2020 20:31:19 -0400 Subject: [PATCH] add m3u8 formats extractor so that user can use -f best --- youtube_dl/extractor/digitalconcerthall.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/youtube_dl/extractor/digitalconcerthall.py b/youtube_dl/extractor/digitalconcerthall.py index ec8fd95d6..b010be267 100644 --- a/youtube_dl/extractor/digitalconcerthall.py +++ b/youtube_dl/extractor/digitalconcerthall.py @@ -45,11 +45,15 @@ class DigitalConcertHallIE(InfoExtractor): entries = [] for key in playlist_dict: print("key: ", key, "\n") - print("key url: ", playlist_dict[key][0]['url'], "\n") + m3u8_url = playlist_dict[key][0]['url'] + print("key url: ", m3u8_url, "\n") + formats = self._extract_m3u8_formats(m3u8_url, key, 'mp4', 'm3u8_native', m3u8_id='hls', fatal=False) + print("formats:\n", formats) entries.append({ - 'id': video_id, - 'title': title + "-" + key, - 'url': playlist_dict[key][0]['url'], + 'id': key, + 'title': title, + 'url': m3u8_url, + 'formats': formats, }) # for i in entries: