From c3f5cd37a4f2631f64e73ca55cb79118d23beb6b Mon Sep 17 00:00:00 2001 From: Benjamin Congdon Date: Mon, 7 Mar 2016 09:42:51 -0600 Subject: [PATCH 1/4] Added option --- youtube_dl/extractor/twitch.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/youtube_dl/extractor/twitch.py b/youtube_dl/extractor/twitch.py index 8639293e3..1b95ed47f 100644 --- a/youtube_dl/extractor/twitch.py +++ b/youtube_dl/extractor/twitch.py @@ -252,6 +252,7 @@ class TwitchVodIE(TwitchItemBaseIE): self._USHER_BASE, item_id, compat_urllib_parse.urlencode({ 'allow_source': 'true', + 'allow_audio_only' : 'true', 'allow_spectre': 'true', 'player': 'twitchweb', 'nauth': access_token['token'], @@ -431,6 +432,7 @@ class TwitchStreamIE(TwitchBaseIE): query = { 'allow_source': 'true', + 'allow_audio_only' : 'true', 'p': random.randint(1000000, 10000000), 'player': 'twitchweb', 'segment_preference': '4', From cc5898150e9b325197d1fbbbdf40be1f2f2efe79 Mon Sep 17 00:00:00 2001 From: Benjamin Congdon Date: Mon, 7 Mar 2016 09:42:51 -0600 Subject: [PATCH 2/4] Added flag for 'allow_audio_only' in Twitch extractor queries --- youtube_dl/extractor/twitch.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/youtube_dl/extractor/twitch.py b/youtube_dl/extractor/twitch.py index 8639293e3..1b95ed47f 100644 --- a/youtube_dl/extractor/twitch.py +++ b/youtube_dl/extractor/twitch.py @@ -252,6 +252,7 @@ class TwitchVodIE(TwitchItemBaseIE): self._USHER_BASE, item_id, compat_urllib_parse.urlencode({ 'allow_source': 'true', + 'allow_audio_only' : 'true', 'allow_spectre': 'true', 'player': 'twitchweb', 'nauth': access_token['token'], @@ -431,6 +432,7 @@ class TwitchStreamIE(TwitchBaseIE): query = { 'allow_source': 'true', + 'allow_audio_only' : 'true', 'p': random.randint(1000000, 10000000), 'player': 'twitchweb', 'segment_preference': '4', From 6a5def49175d0ab7cf21c07d76e910ef37ee528b Mon Sep 17 00:00:00 2001 From: Benjamin Congdon Date: Mon, 7 Mar 2016 15:06:40 -0600 Subject: [PATCH 3/4] Fixed formatting to align with pep8 standard. --- youtube_dl/extractor/twitch.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/youtube_dl/extractor/twitch.py b/youtube_dl/extractor/twitch.py index 1b95ed47f..958bf8fff 100644 --- a/youtube_dl/extractor/twitch.py +++ b/youtube_dl/extractor/twitch.py @@ -252,7 +252,7 @@ class TwitchVodIE(TwitchItemBaseIE): self._USHER_BASE, item_id, compat_urllib_parse.urlencode({ 'allow_source': 'true', - 'allow_audio_only' : 'true', + 'allow_audio_only': 'true', 'allow_spectre': 'true', 'player': 'twitchweb', 'nauth': access_token['token'], @@ -432,7 +432,7 @@ class TwitchStreamIE(TwitchBaseIE): query = { 'allow_source': 'true', - 'allow_audio_only' : 'true', + 'allow_audio_only': 'true', 'p': random.randint(1000000, 10000000), 'player': 'twitchweb', 'segment_preference': '4', From ae97b3a6bb48117f76c97ebd6146354e39df59c6 Mon Sep 17 00:00:00 2001 From: Benjamin Congdon Date: Mon, 7 Mar 2016 09:42:51 -0600 Subject: [PATCH 4/4] Added flag for 'allow_audio_only' in Twitch extractor queries --- youtube_dl/extractor/twitch.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/youtube_dl/extractor/twitch.py b/youtube_dl/extractor/twitch.py index 8639293e3..958bf8fff 100644 --- a/youtube_dl/extractor/twitch.py +++ b/youtube_dl/extractor/twitch.py @@ -252,6 +252,7 @@ class TwitchVodIE(TwitchItemBaseIE): self._USHER_BASE, item_id, compat_urllib_parse.urlencode({ 'allow_source': 'true', + 'allow_audio_only': 'true', 'allow_spectre': 'true', 'player': 'twitchweb', 'nauth': access_token['token'], @@ -431,6 +432,7 @@ class TwitchStreamIE(TwitchBaseIE): query = { 'allow_source': 'true', + 'allow_audio_only': 'true', 'p': random.randint(1000000, 10000000), 'player': 'twitchweb', 'segment_preference': '4',