Merge pull request #451 from pipcat/master
Pepecine, Pelispedia, Flashx
This commit is contained in:
@@ -264,39 +264,47 @@ def listado(item):
|
|||||||
logger.info()
|
logger.info()
|
||||||
itemlist = []
|
itemlist = []
|
||||||
|
|
||||||
action = "findvideos"
|
|
||||||
content_type = "movie"
|
|
||||||
|
|
||||||
if item.extra == 'serie':
|
|
||||||
action = "temporadas"
|
|
||||||
content_type = "tvshow"
|
|
||||||
|
|
||||||
# ~ data = httptools.downloadpage(item.url).data
|
# ~ data = httptools.downloadpage(item.url).data
|
||||||
data = obtener_data(item.url)
|
data = obtener_data(item.url)
|
||||||
data = re.sub(r"\n|\r|\t|\s{2}| |<Br>|<BR>|<br>|<br/>|<br />|-\s", "", data)
|
data = re.sub(r"\n|\r|\t|\s{2}| |<Br>|<BR>|<br>|<br/>|<br />|-\s", "", data)
|
||||||
# logger.info("data -- {}".format(data))
|
|
||||||
|
|
||||||
patron = '<li[^>]+><a href="([^"]+)" alt="([^<|\(]+).*?<img src="([^"]+).*?>.*?<span>\(([^)]+).*?' \
|
if item.extra == 'movies':
|
||||||
'<p class="font12">(.*?)</p>'
|
action = "findvideos"
|
||||||
matches = re.compile(patron, re.DOTALL).findall(data)
|
content_type = "movie"
|
||||||
|
|
||||||
for scrapedurl, scrapedtitle, scrapedthumbnail, scrapedyear, scrapedplot in matches:
|
patron = '<li[^>]+><a href="([^"]+)" alt="([^<|\(]+).*?<img src="([^"]+).*?>.*?<span>\(([^)]+).*?' \
|
||||||
title = "%s (%s)" % (scrapertools.unescape(scrapedtitle.strip()), scrapedyear)
|
'<p class="font12">(.*?)</p>'
|
||||||
plot = scrapertools.entityunescape(scrapedplot)
|
matches = re.compile(patron, re.DOTALL).findall(data)
|
||||||
|
|
||||||
new_item = Item(channel=__channel__, title=title, url=urlparse.urljoin(CHANNEL_HOST, scrapedurl), action=action,
|
for scrapedurl, scrapedtitle, scrapedthumbnail, scrapedyear, scrapedplot in matches:
|
||||||
thumbnail=scrapedthumbnail, plot=plot, context="", extra=item.extra,
|
title = "%s (%s)" % (scrapertools.unescape(scrapedtitle.strip()), scrapedyear)
|
||||||
contentType=content_type, fulltitle=title)
|
plot = scrapertools.entityunescape(scrapedplot)
|
||||||
|
|
||||||
if item.extra == 'serie':
|
new_item = Item(channel=__channel__, title=title, url=urlparse.urljoin(CHANNEL_HOST, scrapedurl), action=action,
|
||||||
new_item.show = scrapertools.unescape(scrapedtitle.strip())
|
thumbnail=scrapedthumbnail, plot=plot, context="", extra=item.extra,
|
||||||
# fix en algunos casos la url está mal
|
contentType=content_type)
|
||||||
new_item.url = new_item.url.replace(CHANNEL_HOST + "pelicula", CHANNEL_HOST + "serie")
|
|
||||||
else:
|
|
||||||
new_item.fulltitle = scrapertools.unescape(scrapedtitle.strip())
|
new_item.fulltitle = scrapertools.unescape(scrapedtitle.strip())
|
||||||
new_item.infoLabels = {'year': scrapedyear}
|
new_item.infoLabels = {'year': scrapedyear}
|
||||||
|
itemlist.append(new_item)
|
||||||
|
|
||||||
|
else:
|
||||||
|
action = "temporadas"
|
||||||
|
content_type = "tvshow"
|
||||||
|
|
||||||
|
patron = '<li[^>]+><a href="([^"]+)" alt="([^<|\(]+).*?<img src="([^"]+)'
|
||||||
|
matches = re.compile(patron, re.DOTALL).findall(data)
|
||||||
|
|
||||||
|
for scrapedurl, scrapedtitle, scrapedthumbnail in matches:
|
||||||
|
title = scrapertools.unescape(scrapedtitle.strip())
|
||||||
|
|
||||||
|
new_item = Item(channel=__channel__, title=title, url=urlparse.urljoin(CHANNEL_HOST, scrapedurl), action=action,
|
||||||
|
thumbnail=scrapedthumbnail, context="", extra=item.extra,
|
||||||
|
contentType=content_type, fulltitle=title)
|
||||||
|
new_item.show = title
|
||||||
|
# fix en algunos casos la url está mal
|
||||||
|
new_item.url = new_item.url.replace(CHANNEL_HOST + "pelicula", CHANNEL_HOST + "serie")
|
||||||
|
itemlist.append(new_item)
|
||||||
|
|
||||||
itemlist.append(new_item)
|
|
||||||
|
|
||||||
# Obtenemos los datos basicos de todas las peliculas mediante multihilos
|
# Obtenemos los datos basicos de todas las peliculas mediante multihilos
|
||||||
tmdb.set_infoLabels(itemlist, __modo_grafico__)
|
tmdb.set_infoLabels(itemlist, __modo_grafico__)
|
||||||
|
|||||||
@@ -62,7 +62,7 @@ def mainlist(item):
|
|||||||
type = 'series'))
|
type = 'series'))
|
||||||
|
|
||||||
itemlist.append(item.clone(title = "Buscar",
|
itemlist.append(item.clone(title = "Buscar",
|
||||||
url = host + '/donde-ver?q=',
|
url = host + '/ver-online?q=',
|
||||||
action ='search',
|
action ='search',
|
||||||
type = 'movie'))
|
type = 'movie'))
|
||||||
|
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ def test_video_exists(page_url):
|
|||||||
logger.info("(page_url='%s')" % page_url)
|
logger.info("(page_url='%s')" % page_url)
|
||||||
|
|
||||||
data = httptools.downloadpage(page_url, cookies=False).data
|
data = httptools.downloadpage(page_url, cookies=False).data
|
||||||
if 'file was deleted' in data:
|
if 'file was deleted' in data or 'File Not Found (Deleted or Abused)' in data:
|
||||||
return False, config.get_localized_string(70292) % "FlashX"
|
return False, config.get_localized_string(70292) % "FlashX"
|
||||||
elif 'Video is processing now' in data:
|
elif 'Video is processing now' in data:
|
||||||
return False, config.get_localized_string(70293) % "FlashX"
|
return False, config.get_localized_string(70293) % "FlashX"
|
||||||
|
|||||||
Reference in New Issue
Block a user