From ac37c0ac55da0ea8884e546a8cc3a0a7dd0aad79 Mon Sep 17 00:00:00 2001 From: "J.D. Purcell" Date: Mon, 23 Oct 2017 10:40:39 -0400 Subject: [PATCH 1/2] [twitch] Fix clip title detection. --- youtube_dl/extractor/twitch.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/youtube_dl/extractor/twitch.py b/youtube_dl/extractor/twitch.py index c926c99a9..5485f9f42 100644 --- a/youtube_dl/extractor/twitch.py +++ b/youtube_dl/extractor/twitch.py @@ -609,7 +609,7 @@ class TwitchClipsIE(InfoExtractor): r'(?s)clipInfo\s*=\s*({.+?});', webpage, 'clip info'), video_id, transform_source=js_to_json) - title = clip.get('channel_title') or self._og_search_title(webpage) + title = clip.get('title') or self._og_search_title(webpage) formats = [{ 'url': option['source'], From f5b3bc52ec92e360b6fcc2830e1c5d119daebfd6 Mon Sep 17 00:00:00 2001 From: "J.D. Purcell" Date: Mon, 23 Oct 2017 12:08:41 -0400 Subject: [PATCH 2/2] Keep old channel_title property as a fallback. --- youtube_dl/extractor/twitch.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/youtube_dl/extractor/twitch.py b/youtube_dl/extractor/twitch.py index 5485f9f42..fefcd2807 100644 --- a/youtube_dl/extractor/twitch.py +++ b/youtube_dl/extractor/twitch.py @@ -609,7 +609,7 @@ class TwitchClipsIE(InfoExtractor): r'(?s)clipInfo\s*=\s*({.+?});', webpage, 'clip info'), video_id, transform_source=js_to_json) - title = clip.get('title') or self._og_search_title(webpage) + title = clip.get('title') or clip.get('channel_title') or self._og_search_title(webpage) formats = [{ 'url': option['source'],