From a3bfb3b184629430da230a27c2d3134def364792 Mon Sep 17 00:00:00 2001 From: Alhaziel01 Date: Fri, 17 Dec 2021 18:14:58 +0100 Subject: [PATCH] Revert "Test StreamingCommunity" This reverts commit 139a7fe588ed2e3754ea8cc330b961464ac8d472. --- channels/streamingcommunity.py | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/channels/streamingcommunity.py b/channels/streamingcommunity.py index 73109bfb..ba6891bd 100644 --- a/channels/streamingcommunity.py +++ b/channels/streamingcommunity.py @@ -220,7 +220,6 @@ def play(item): from time import time from base64 import b64encode from hashlib import md5 - video_urls = [] data = support.httptools.downloadpage(item.url + item.episodeid, headers=headers).data.replace('"','"').replace('\\','') scws_id = support.match(data, patron=r'scws_id"\s*:\s*(\d+)').match @@ -233,9 +232,6 @@ def play(item): expires = int(time() + 172800) token = b64encode(md5('{}{} Yc8U6r8KjAKAepEA'.format(expires, client_ip).encode('utf-8')).digest()).decode('utf-8').replace('=', '').replace('+', '-').replace('/', '_') - sub = 'https://scws.xyz/master/{}?token={}&expires={}&n=1'.format(scws_id, token, expires) - urls = support.match(sub, patron=r'RESOLUTION=\d+x(\d+)(?:\s*,\s*SUBTITLES="[^"]+")\s*([^\s\n]+)').matches - for quality, url in urls: - video_urls.append(['hls [{}p]'.format(quality),url]) + url = 'https://scws.xyz/master/{}?token={}&expires={}&n=1'.format(scws_id, token, expires) - return [item.clone(title = channeltools.get_channel_parameters(item.channel)['title'], server='directo', video_urls=video_urls, manifest='hls', subtitle=sub)] + return [item.clone(title = channeltools.get_channel_parameters(item.channel)['title'], server='directo', url=url)]