Cb01: esclusione definitiva articoli di servizio, toonitalia fix sezione aggiornamenti, piccole migliorie
This commit is contained in:
@@ -91,13 +91,14 @@ def search(item, text):
|
||||
|
||||
@support.scrape
|
||||
def peliculas(item):
|
||||
# debug = True
|
||||
# esclusione degli articoli 'di servizio'
|
||||
curYear = datetime.date.today().year
|
||||
blacklist = ['BENVENUTI', 'Richieste Serie TV', 'CB01.UNO ▶ TROVA L’INDIRIZZO UFFICIALE ',
|
||||
'Aggiornamento Quotidiano Serie TV', 'AVVISO!!!',
|
||||
'Openload: la situazione. Benvenuto Verystream', 'Openload: lo volete ancora?',
|
||||
'OSCAR ' + str(curYear) + ' ▶ VOTA IL TUO FILM PREFERITO! 🎬',
|
||||
'Auguri di Buon Natale e Felice Anno Nuovo! – ' + str(curYear) + '!']
|
||||
# curYear = datetime.date.today().year
|
||||
# blacklist = ['BENVENUTI', 'Richieste Serie TV', 'CB01.UNO ▶ TROVA L’INDIRIZZO UFFICIALE ',
|
||||
# 'Aggiornamento Quotidiano Serie TV', 'AVVISO!!!',
|
||||
# 'Openload: la situazione. Benvenuto Verystream', 'Openload: lo volete ancora?',
|
||||
# 'OSCAR ' + str(curYear) + ' ▶ VOTA IL TUO FILM PREFERITO! 🎬',
|
||||
# 'Auguri di Buon Natale e Felice Anno Nuovo! – ' + str(curYear) + '!']
|
||||
|
||||
if 'newest' in item.args:
|
||||
pagination = ''
|
||||
@@ -110,11 +111,11 @@ def peliculas(item):
|
||||
action = 'episodios'
|
||||
|
||||
elif '/serietv/' not in item.url:
|
||||
patron = r'<div class="card-image">\s*<a[^>]+>\s*<img src="(?P<thumb>[^" ]+)" alt[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+><a href="?(?P<url>[^" >]+)(?:\/|"|\s+)>(?P<title>[^<[(]+)(?:\[(?P<quality>[a-zA-Z/]+)\]\s*)?(?:\[(?P<lang>Sub-ITA|ITA)\]\s*)?(?:\[(?P<quality2>[a-zA-Z/]+)\]\s*)? (?:\((?P<year>[0-9]{4})\))?[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>(?P<genre>[^<>&âÃÂÖ]+)(?:[^ ]+\s*DURATA\s*(?P<duration>[0-9]+)[^>]+>[^>]+>[^>]+>(?P<plot>[^<>]+))?'
|
||||
patron = r'(?<!sticky )hentry.*?<div class="card-image">\s*<a[^>]+>\s*<img src="(?P<thumb>[^" ]+)" alt[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+><a href="?(?P<url>[^" >]+)(?:\/|"|\s+)>(?P<title>[^<[(]+)(?:\[(?P<quality>[a-zA-Z/]+)\]\s*)?(?:\[(?P<lang>Sub-ITA|ITA)\]\s*)?(?:\[(?P<quality2>[a-zA-Z/]+)\]\s*)? (?:\((?P<year>[0-9]{4})\))?[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>(?P<genre>[^<>&âÃÂÖ]+)(?:[^ ]+\s*DURATA\s*(?P<duration>[0-9]+)[^>]+>[^>]+>[^>]+>(?P<plot>[^<>]+))?'
|
||||
action = 'findvideos'
|
||||
|
||||
else:
|
||||
patron = r'card-image[^>]*>\s*<a href=(?:")?(?P<url>[^" >]+)(?:")?\s*>\s*<img src=(?:")?(?P<thumb>[^" ]+)(?:")? alt="(?P<title>.*?)(?: – \d+×\d+)?(?:"| – )(?:(?P<lang>Sub-ITA|ITA))?[^>]*>[^>]+>[^>]+>[^>]*>[^>]+>[^>]+>[^>]*>[^>]+>[^>]+>[^>]*>[^>]+>[^>]+>[^>]*>(?P<genre>[^\(]+)\((?P<year>\d{4})[^>]*>[^>]+>[^>]+>[^>]+>(?:<p>)?(?P<plot>[^<]+)'
|
||||
patron = r'(?<!sticky )hentry.*?card-image[^>]*>\s*<a href=(?:")?(?P<url>[^" >]+)(?:")?\s*>\s*<img src=(?:")?(?P<thumb>[^" ]+)(?:")? alt="(?P<title>.*?)(?: – \d+×\d+)?(?:"| – )(?:(?P<lang>Sub-ITA|ITA))?[^>]*>[^>]+>[^>]+>[^>]*>[^>]+>[^>]+>[^>]*>[^>]+>[^>]+>[^>]*>[^>]+>[^>]+>[^>]*>(?P<genre>[^\(]+)\((?P<year>\d{4})[^>]*>[^>]+>[^>]+>[^>]+>(?:<p>)?(?P<plot>[^<]+)'
|
||||
action = 'episodios'
|
||||
item.contentType = 'tvshow'
|
||||
|
||||
|
||||
@@ -105,6 +105,7 @@ def episodios(item):
|
||||
# debugBlock = True
|
||||
return locals()
|
||||
|
||||
|
||||
@support.scrape
|
||||
def genres(item):
|
||||
info(item)
|
||||
@@ -119,9 +120,11 @@ def genres(item):
|
||||
patronBlock = r'<div class="movies-letter">(?P<block>.*?)<div class="clearfix">'
|
||||
|
||||
patronMenu = r'<a(?:.+?)?href="(?P<url>.*?)"[ ]?>(?P<title>.*?)<\/a>'
|
||||
# debugBlock = True
|
||||
|
||||
return locals()
|
||||
|
||||
|
||||
def search(item, text):
|
||||
info(text)
|
||||
import uuid
|
||||
|
||||
@@ -71,7 +71,7 @@ def peliculas(item):
|
||||
#patron = r'href="(?P<url>[^"]+)" title="(?P<title>[^"]+)"'
|
||||
patron = r'<a href="(?P<url>[^"]+)"[^>]*>(?P<title>[^<]+)<[^>]+>[^>]+>\s*<div'
|
||||
elif item.args == 'last':
|
||||
patronBlock = 'Aggiornamenti</h2>(?P<block>.*)</ul>'
|
||||
patronBlock = '(?:Aggiornamenti|Update)</h2>(?P<block>.*?)</ul>'
|
||||
patron = r'<a href="(?P<url>[^"]+)">\s*<img[^>]+src[set]{0,3}="(?P<thumbnail>[^ ]+)[^>]+>\s*<span[^>]+>(?P<title>[^<]+)'
|
||||
else:
|
||||
patronBlock = '<main[^>]+>(?P<block>.*)</main>'
|
||||
|
||||
@@ -34,7 +34,7 @@ def get_video_url(page_url, premium=False, user="", password="", video_password=
|
||||
# support.dbg()
|
||||
url = data.get('result',{}).get('playlist')
|
||||
|
||||
video_urls.append([url.split('.')[-1], url + '|Referer:' + page_url])
|
||||
video_urls.append([url.split('.')[-1], url + '|Referer=' + page_url])
|
||||
|
||||
return video_urls
|
||||
|
||||
|
||||
@@ -2,12 +2,10 @@
|
||||
# --------------------------------------------------------
|
||||
# Conector playtube By Alfa development Group
|
||||
# --------------------------------------------------------
|
||||
import re
|
||||
import codecs
|
||||
from core import httptools
|
||||
from core import scrapertools
|
||||
from lib import jsunpack
|
||||
from platformcode import logger
|
||||
from platformcode import logger, config
|
||||
|
||||
|
||||
def test_video_exists(page_url):
|
||||
@@ -24,6 +22,6 @@ def get_video_url(page_url, premium=False, user="", password="", video_password=
|
||||
video_urls = []
|
||||
pack = scrapertools.find_single_match(data.data, 'p,a,c,k,e,d.*?</script>')
|
||||
unpacked = jsunpack.unpack(pack)
|
||||
url = scrapertools.find_single_match(unpacked, 'file:"([^"]+)') + "|referer=%s" %(page_url)
|
||||
url = scrapertools.find_single_match(unpacked, 'file:"([^"]+)') + "|Referer=%s" % page_url
|
||||
video_urls.append(['m3u8 [PlayTube]', url] )
|
||||
return video_urls
|
||||
@@ -11,7 +11,7 @@ def test_video_exists(page_url):
|
||||
data = httptools.downloadpage(page_url).data
|
||||
if 'File was deleted' in data:
|
||||
return False, config.get_localized_string(70449) % 'YouDbox'
|
||||
return True
|
||||
return True, ""
|
||||
|
||||
|
||||
def get_video_url(page_url, video_password):
|
||||
|
||||
Reference in New Issue
Block a user