diff --git a/channels/cineblog01.py b/channels/cineblog01.py index a2cb2401..f2c803cc 100644 --- a/channels/cineblog01.py +++ b/channels/cineblog01.py @@ -25,7 +25,7 @@ def findhost(): IDIOMAS = {'Italiano': 'IT'} list_language = IDIOMAS.values() list_servers = ['verystream', 'openload', 'streamango', 'wstream'] -list_quality = ['HD', 'default'] +list_quality = ['HD', 'SD', 'default'] checklinks = config.get_setting('checklinks', 'cineblog01') checklinks_number = config.get_setting('checklinks_number', 'cineblog01') @@ -33,7 +33,7 @@ checklinks_number = config.get_setting('checklinks_number', 'cineblog01') # esclusione degli articoli 'di servizio' blacklist = ['BENVENUTI', 'Richieste Serie TV', 'CB01.UNO ▶ TROVA L’INDIRIZZO UFFICIALE ', 'Aggiornamento Quotidiano Serie TV', 'OSCAR 2019 â–¶ CB01.UNO: Vota il tuo film preferito! 🎬', - 'Openload: la situazione. Benvenuto Verystream'] + 'Openload: la situazione. Benvenuto Verystream', 'Openload: lo volete ancora?'] def mainlist(item): @@ -230,11 +230,10 @@ def findvideos(item): matches = re.compile(patron, re.DOTALL).findall(streaming) for scrapedurl, scrapedtitle in matches: logger.debug("##### findvideos %s ## %s ## %s ##" % (desc_txt, scrapedurl, scrapedtitle)) - title = "[COLOR " + color + "]" + desc_txt + ":[/COLOR] " + item.fulltitle + " [COLOR grey]" + QualityStr + "[/COLOR] [COLOR blue][" + scrapedtitle + "][/COLOR]" itemlist.append( Item(channel=item.channel, action="play", - title=title, + title=scrapedtitle, url=scrapedurl, server=scrapedtitle, fulltitle=item.fulltitle, @@ -265,37 +264,18 @@ def findvideos(item): # Estrae i contenuti - Streaming HD load_links(itemlist, 'Streaming HD[^<]+(.*?)', "yellow", "Streaming HD", "HD") - autoplay.start(itemlist, item) - # Estrae i contenuti - Streaming 3D load_links(itemlist, 'Streaming 3D[^<]+(.*?)', "pink", "Streaming 3D") + support.videolibrary(itemlist, item) + return support.server(item, itemlist=itemlist) + # Estrae i contenuti - Download # load_links(itemlist, 'Download:(.*?)', "aqua", "Download") # Estrae i contenuti - Download HD # load_links(itemlist, 'Download HD[^<]+(.*?)', "azure", "Download HD") - if len(itemlist) == 0: - itemlist = servertools.find_video_items(item=item) - - # Requerido para Filtrar enlaces - - if checklinks: - itemlist = servertools.check_list_links(itemlist, checklinks_number) - - # Requerido para FilterTools - - # itemlist = filtertools.get_links(itemlist, item, list_language) - - # Requerido para AutoPlay - - autoplay.start(itemlist, item) - - support.videolibrary(itemlist, item) - - return itemlist - def findvid_serie(item): def load_vid_series(html, item, itemlist, blktxt): @@ -306,11 +286,11 @@ def findvid_serie(item): for match in matches: scrapedurl = match.group(1) scrapedtitle = match.group(2) - title = item.title + " [COLOR blue][" + scrapedtitle + "][/COLOR]" + # title = item.title + " [COLOR blue][" + scrapedtitle + "][/COLOR]" itemlist.append( Item(channel=item.channel, action="play", - title=title, + title=scrapedtitle, url=scrapedurl, server=scrapedtitle, fulltitle=item.fulltitle, @@ -354,9 +334,7 @@ def findvid_serie(item): else: load_vid_series(data[lnkblkp[i]:lnkblkp[i + 1]], item, itemlist, lnkblk[i]) - autoplay.start(itemlist, item) - - return itemlist + return support.server(item, itemlist=itemlist) def play(item): @@ -390,4 +368,4 @@ def play(item): else: data = support.swzz_get_url(item) - return support.server(item, data, headers) + return servertools.find_video_items(data=data) diff --git a/channels/eurostreaming.py b/channels/eurostreaming.py index 3197c73a..224e6cd8 100644 --- a/channels/eurostreaming.py +++ b/channels/eurostreaming.py @@ -56,7 +56,7 @@ def serietv(item): if item.args: # il titolo degli episodi viene inglobato in episode ma non sono visibili in newest!!! patron = r'(.*?).[^–](.*?)<\/a>' - listGroups = ['title', 'url', 'episode'] + listGroups = ['title', 'url', 'title2'] patronNext = '' else: patron = r'
.*?\s(.*?(?:\((\d{4})\)|(\d{4}))?)<\/a><\/h2>' diff --git a/channels/ilgeniodellostreaming.py b/channels/ilgeniodellostreaming.py index 92b4aff1..a10e37bb 100644 --- a/channels/ilgeniodellostreaming.py +++ b/channels/ilgeniodellostreaming.py @@ -4,83 +4,51 @@ # Canale per ilgeniodellostreaming # ------------------------------------------------------------ import re -import urlparse -from core import scrapertools, servertools, httptools -from core import tmdb +from platformcode import logger +from core import scrapertoolsV2, httptools, tmdb, support +from core.support import log, menu, aplay from core.item import Item -from platformcode import config, logger -from specials import autoplay - -__channel__ = "ilgeniodellostreaming" host = "https://ilgeniodellostreaming.pw" IDIOMAS = {'Italiano': 'IT'} list_language = IDIOMAS.values() -list_servers = ['verystream', 'openload', 'streamango', 'youtube'] +list_servers = ['verystream', 'openload', 'streamango'] list_quality = ['default'] - -checklinks = config.get_setting('checklinks', 'ilgeniodellostreaming') -checklinks_number = config.get_setting('checklinks_number', 'ilgeniodellostreaming') - headers = [['Referer', host]] PERPAGE = 10 def mainlist(item): - logger.info("kod.ilgeniodellostreaming mainlist") - - autoplay.init(item.channel, list_servers, list_quality) - itemlist = [Item(channel=__channel__, - title="[COLOR azure]Ultimi Film Inseriti[/COLOR]", - action="peliculas", - url="%s/film/" % host, - thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"), - Item(channel=__channel__, - title="[COLOR azure]Film Per Categoria[/COLOR]", - action="categorias", - url=host, - thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png"), - Item(channel=__channel__, - title="[COLOR azure]Serie TV[/COLOR]", - action="serie", - url="%s/serie/" % host, - thumbnail="http://www.ilmioprofessionista.it/wp-content/uploads/2015/04/TVSeries3.png"), - Item(channel=__channel__, - title="[COLOR azure]Nuovi Episodi Serie TV[/COLOR]", - action="nuoviep", - url="%s/aggiornamenti-serie/" % host, - thumbnail="http://www.ilmioprofessionista.it/wp-content/uploads/2015/04/TVSeries3.png"), - Item(channel=__channel__, - title="[COLOR azure]Anime[/COLOR]", - action="serie", - url="%s/anime/" % host, - thumbnail="http://orig09.deviantart.net/df5a/f/2014/169/2/a/fist_of_the_north_star_folder_icon_by_minacsky_saya-d7mq8c8.png"), - Item(channel=__channel__, - title="[COLOR yellow]Cerca...[/COLOR]", - action="search", - extra="movie", - thumbnail="http://dc467.4shared.com/img/fEbJqOum/s7/13feaf0c8c0/Search")] - - autoplay.show_option(item.channel, itemlist) - + log() + itemlist = [] + menu(itemlist, 'Film', 'peliculas', host + '/film/') + menu(itemlist, 'Film Per Categoria', 'category', host, args='genres') + menu(itemlist, 'Film Per Anno', 'category', host, args='year') + menu(itemlist, 'Serie TV', 'peliculas', host + '/serie/', 'episode') + menu(itemlist, 'Nuovi Episodi Serie TV submenu', 'newep', host + '/aggiornamenti-serie/', 'episode') + menu(itemlist, 'Anime', 'peliculas', host + '/anime/', 'episode') + menu(itemlist, 'TV Show', 'peliculas', host + '/tv-show/', 'episode') + menu(itemlist, 'Cerca...', 'search', contentType='search') + aplay(item, itemlist, list_servers, list_quality) return itemlist def newest(categoria): - logger.info("kod.ilgeniodellostreaming newest" + categoria) + log(categoria) itemlist = [] item = Item() try: - if categoria == "film": - item.url = "%s/film/" % host - item.action = "peliculas" - itemlist = peliculas(item) + if categoria == "movie": item.url = host + '/film/' + elif categoria == "tvshow": item.url = host + '/serie/' + elif categoria == "anime": item.url = host + '/anime/' + item.action = "peliculas" + itemlist = peliculas(item) - if itemlist[-1].action == "peliculas": - itemlist.pop() + if itemlist[-1].action == "peliculas": + itemlist.pop() # Continua la ricerca in caso di errore except: import sys @@ -91,37 +59,16 @@ def newest(categoria): return itemlist -def categorias(item): - logger.info("kod.ilgeniodellostreaming categorias") - itemlist = [] - - # Carica la pagina - data = httptools.downloadpage(item.url).data - bloque = scrapertools.find_single_match(data, '
    (.*?)
') - - # Estrae i contenuti - patron = ']+>
]+>(.*?)' - matches = re.compile(patron, re.DOTALL).findall(bloque) - - for scrapedurl, scrapedtitle in matches: - logger.info("title=[" + scrapedtitle + "]") - itemlist.append( - Item(channel=__channel__, - action="peliculas", - title="[COLOR azure]" + scrapedtitle + "[/COLOR]", - url=scrapedurl, - thumbnail="http://orig03.deviantart.net/6889/f/2014/079/7/b/movies_and_popcorn_folder_icon_by_matheusgrilo-d7ay4tw.png", - folder=True)) - - return itemlist +def category(item): + return support.scrape(item, r']+>(.*?)<\/a>' ,['url', 'title'], action='peliculas', patron_block= r'