diff --git a/plugin.video.alfa/channels/cinecalidad.py b/plugin.video.alfa/channels/cinecalidad.py index 82bc494da..766105990 100644 --- a/plugin.video.alfa/channels/cinecalidad.py +++ b/plugin.video.alfa/channels/cinecalidad.py @@ -70,10 +70,10 @@ 'get_quality': {}, 'get_quality_rgx': [], 'next_page': {}, - 'next_page_rgx': [['\/page\/\d+', '/page/%s/']], + 'next_page_rgx': [[r'\/page\/\d+', '/page/%s/']], 'last_page': dict([('find', [{'tag': ['nav'], 'class': ['pagination']}]), ('find_all',[{'tag': ['a'], '@POS': [-2]}]), - ('get_text', [{'tag': '', '@STRIP': True, '@TEXT': '(\d+)'}])]), + ('get_text', [{'tag': '', '@STRIP': True, '@TEXT': r'(\d+)'}])]), 'year': {}, 'season_episode': {}, 'seasons': {}, @@ -86,14 +86,14 @@ 'episode_clean': [], 'plot': {}, 'findvideos': {'find_all': [{'tag': ['a'], 'class': ['inline-block']}]}, - 'title_clean': [['(?i)TV|Online|(4k-hdr)|(fullbluray)|4k| - 4k|(3d)|miniserie|\s*imax', ''], - ['(?i)[\[|\(]?\d{3,4}p[\]|\)]?|[\[|\(]?(?:4k|3d|uhd|hdr)[\]|\)]?', ''], - ['(?i)[-|\(]?\s*HDRip\)?|microHD|\(?BR-LINE\)?|\(?HDTS-SCREENER\)?', ''], - ['(?i)\(?BDRip\)?|\(?BR-Screener\)?|\(?DVDScreener\)?|\(?TS-Screener\)?|[\(|\[]\S*\.*$', ''], - ['(?i)Castellano-*|Ingl.s|Trailer|Audio|\(*SBS\)*|\[*\(*dvd\s*r\d*\w*\]*\)*|[\[|\(]*dv\S*[\)|\]]*', ''], - ['(?i)Dual|Subt\w*|\(?Reparado\)?|\(?Proper\)?|\(?Latino\)?|saga(?:\s*del)?', ''], - ['(?i)(?:\s*–)?\s*temp.*?\d+.*', ''], ['\d?\d?.*', ''], ['\d+[x|×]\d+.*', ''], - ['[\(|\[]\s*[\)|\]]', ''], ['(?i)(?:libro|volumen)?\s+\d{1,2}$', '']], + 'title_clean': [[r'(?i)TV|Online|(4k-hdr)|(fullbluray)|4k| - 4k|(3d)|miniserie|\s*imax', ''], + [r'(?i)[\[|\(]?\d{3,4}p[\]|\)]?|[\[|\(]?(?:4k|3d|uhd|hdr)[\]|\)]?', ''], + [r'(?i)[-|\(]?\s*HDRip\)?|microHD|\(?BR-LINE\)?|\(?HDTS-SCREENER\)?', ''], + [r'(?i)\(?BDRip\)?|\(?BR-Screener\)?|\(?DVDScreener\)?|\(?TS-Screener\)?|[\(|\[]\S*\.*$', ''], + [r'(?i)Castellano-*|Ingl.s|Trailer|Audio|\(*SBS\)*|\[*\(*dvd\s*r\d*\w*\]*\)*|[\[|\(]*dv\S*[\)|\]]*', ''], + [r'(?i)Dual|Subt\w*|\(?Reparado\)?|\(?Proper\)?|\(?Latino\)?|saga(?:\s*del)?', ''], + [r'(?i)(?:\s*–)?\s*temp.*?\d+.*', ''], [r'\d?\d?.*', ''], [r'\d+[x|×]\d+.*', ''], + [r'[\(|\[]\s*[\)|\]]', ''], [r'(?i)(?:libro|volumen)?\s+\d{1,2}$', '']], 'quality_clean': [['(?i)proper|unrated|directors|cut|repack|internal|real|extended|masted|docu|super|duper|amzn|uncensored|hulu', '']], 'language_clean': [], 'url_replace': [], @@ -310,7 +310,7 @@ def list_all_matches(item, matches_int, **AHkwargs): try: elem_json['url'] = elem.a.get("href", "") if '/serie' in elem_json['url']: continue - if scrapertools.find_single_match(elem_json['url'], "\d+x\d+") or "episode" in elem_json['url']: continue + if scrapertools.find_single_match(elem_json['url'], r"\d+x\d+") or "episode" in elem_json['url']: continue if sufix[item.site or 0] and sufix[item.site or 0] not in elem_json['url']: elem_json['url'] += sufix[item.site or 0] @@ -322,7 +322,7 @@ def list_all_matches(item, matches_int, **AHkwargs): if not elem_json.get('year'): elem_json['year'] = '-' - if elem.find('div'): elem_json['year'] = scrapertools.find_single_match(elem.find('div').get_text(strip=True), '\d{4}') or '-' + if elem.find('div'): elem_json['year'] = scrapertools.find_single_match(elem.find('div').get_text(strip=True), r'\d{4}') or '-' elem_json['thumbnail'] = re.sub(r'(-\d+x\d+.jpg)', '.jpg', elem.find('img', class_="w-full").get("data-src", "") \ or elem.find('img', class_="w-full").get("src", "")) diff --git a/plugin.video.alfa/channels/cuevana2.py b/plugin.video.alfa/channels/cuevana2.py index 089bfe96e..1cb131813 100644 --- a/plugin.video.alfa/channels/cuevana2.py +++ b/plugin.video.alfa/channels/cuevana2.py @@ -49,13 +49,13 @@ 'get_quality': {}, 'get_quality_rgx': '', 'next_page': {}, - 'next_page_rgx': [['\/page\/\d+', '/page/%s']], + 'next_page_rgx': [[r'\/page\/\d+', '/page/%s']], 'last_page': dict([('find', [{'tag': ['ul'], 'class': ['pagination']}, {'tag': ['span'], 'class': ['visually-hidden'], 'string': re.compile('(?i)Last')}]), - ('find_previous', [{'tag': ['a'], 'class': ['page-link'], '@ARG': 'href', '@TEXT': '(\d+)'}])]), + ('find_previous', [{'tag': ['a'], 'class': ['page-link'], '@ARG': 'href', '@TEXT': r'(\d+)'}])]), 'year': dict([('find', [{'tag': ['div'], 'class': ['MovieItem_data__BdOz3', 'SerieItem_data__LFJR_']}, {'tag': ['span']}]), - ('get_text', [{'strip': True, '@TEXT': '(\d{4})'}])]), + ('get_text', [{'strip': True, '@TEXT': r'(\d{4})'}])]), 'season_episode': dict([('find', [{'tag': ['div'], 'class': ['EpisodeItem_data__jsvqZ']}, {'tag': ['span']}]), ('get_text', [{'tag': '', '@STRIP': True}])]), @@ -72,8 +72,8 @@ 'plot': {}, 'findvideos': dict([('find', [{'tag': ['script'], 'id': ['__NEXT_DATA__']}]), ('get_text', [{'tag': '', '@STRIP': False, '@JSON': 'props,pageProps,episode/post,players|DEFAULT'}])]), - 'title_clean': [['(?i)TV|Online|(4k-hdr)|(fullbluray)|4k| - 4k|(3d)|miniserie|\s*\(\d{4}\)', ''], - ['[\(|\[]\s*[\)|\]]', '']], + 'title_clean': [[r'(?i)TV|Online|(4k-hdr)|(fullbluray)|4k| - 4k|(3d)|miniserie|\s*\(\d{4}\)', ''], + [r'[\(|\[]\s*[\)|\]]', '']], 'quality_clean': [['(?i)proper|unrated|directors|cut|repack|internal|real|extended|masted|docu|super|duper|amzn|uncensored|hulu', '']], 'language_clean': [], 'url_replace': [], @@ -312,7 +312,7 @@ def play(item): return [] soup = soup.find("script", string=re.compile('start.onclick')).string - item.url = scrapertools.find_single_match(str(soup), "url\s*=\s*'([^']+)'") + item.url = scrapertools.find_single_match(str(soup), r"url\s*=\s*'([^']+)'") if item.url: itemlist = servertools.get_servers_itemlist([item]) else: diff --git a/plugin.video.alfa/channels/dontorrent.py b/plugin.video.alfa/channels/dontorrent.py index 47996990f..f52e782d3 100644 --- a/plugin.video.alfa/channels/dontorrent.py +++ b/plugin.video.alfa/channels/dontorrent.py @@ -25,9 +25,10 @@ canonical = { 'channel': 'dontorrent', 'host': config.get_setting("current_host", 'dontorrent', default=''), - 'host_alt': ["https://dontorrent.prof/", "https://lilatorrent.com/", "https://todotorrents.org/", "https://elitedivx.net/"], - 'host_alt_new': ["https://dontorrent.prof/"], - 'host_black_list': ["https://dontorrent.club/", "https://www21.dontorrent.link/", + 'host_alt': ["https://dontorrent.promo/", "https://lilatorrent.com/", "https://todotorrents.org/", "https://elitedivx.net/"], + 'host_alt_new': ["https://dontorrent.promo/"], + 'host_black_list': ["https://dontorrent.info/", + "https://dontorrent.prof/", "https://dontorrent.club/", "https://www21.dontorrent.link/", "https://dontorrent.sarl/", "https://dontorrent.gripe/", "https://reinventorrent.org/", "https://dontorrent.phd/", "https://dontorrent.live/", "https://dontorrent.kiwi/", "https://dontorrent.kids/", "https://dontorrent.onl/", "https://dontorrent.istanbul/", @@ -772,8 +773,8 @@ def findvideos_matches(item, matches_int, langs, response, **AHkwargs): if '3d' in elem_json['url'].lower() and '3d' not in elem_json['quality'].lower(): elem_json['quality'] = '%s,3d' % elem_json['quality'] - if elem.find('b', class_='bold', string=re.compile('Clave:\s*')): - elem_json['password'] = elem.find('b', class_='bold', string=re.compile('Clave:\s*'))\ + if elem.find('b', class_='bold', string=re.compile(r'Clave:\s*')): + elem_json['password'] = elem.find('b', class_='bold', string=re.compile(r'Clave:\s*'))\ .find_next('a').get('data-content', '') elem_json['password'] = item.password = scrapertools.find_single_match(elem_json['password'], "value='([^']+)'") except Exception: diff --git a/plugin.video.alfa/channels/grantorrent.py b/plugin.video.alfa/channels/grantorrent.py index b4fb16266..663338e57 100644 --- a/plugin.video.alfa/channels/grantorrent.py +++ b/plugin.video.alfa/channels/grantorrent.py @@ -30,7 +30,7 @@ "https://www1.grantorrent.wf/", "https://www1.grantorrent.pm/", "https://grantorrent.zip/", 'https://grantorrent.bz/', 'https://grantorrent.fi/', 'https://grantorrent.si/', 'https://grantorrent.re/', 'https://grantorrent.ac/', 'https://grantorrent.ch/'], - 'pattern': '