瀏覽代碼

[twitch:stream] Add support for rebroadcasts (closes #10995)

Sergey M․ 9 年之前
父節點
當前提交
9aa929d337
共有 1 個文件被更改,包括 2 次插入1 次删除
  1. 2 1
      youtube_dl/extractor/twitch.py

+ 2 - 1
youtube_dl/extractor/twitch.py

@@ -398,7 +398,7 @@ class TwitchStreamIE(TwitchBaseIE):
         channel_id = self._match_id(url)
 
         stream = self._call_api(
-            'kraken/streams/%s' % channel_id, channel_id,
+            'kraken/streams/%s?stream_type=all' % channel_id, channel_id,
             'Downloading stream JSON').get('stream')
 
         if not stream:
@@ -417,6 +417,7 @@ class TwitchStreamIE(TwitchBaseIE):
         query = {
             'allow_source': 'true',
             'allow_audio_only': 'true',
+            'allow_spectre': 'true',
             'p': random.randint(1000000, 10000000),
             'player': 'twitchweb',
             'segment_preference': '4',