@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||||
<addon id="plugin.video.alfa" name="Alfa" version="0.0.4" provider-name="unknown">
|
<addon id="plugin.video.alfa" name="Alfa" version="0.0.7" provider-name="unknown">
|
||||||
<requires>
|
<requires>
|
||||||
<import addon="xbmc.python" version="2.1.0"/>
|
<import addon="xbmc.python" version="2.1.0"/>
|
||||||
<import addon="script.module.libtorrent" optional="true"/>
|
<import addon="script.module.libtorrent" optional="true"/>
|
||||||
@@ -11,19 +11,11 @@
|
|||||||
<summary lang="es">Sumario en Español</summary>
|
<summary lang="es">Sumario en Español</summary>
|
||||||
<news>[B]Estos son los cambios para esta versión:[/B][CR]
|
<news>[B]Estos son los cambios para esta versión:[/B][CR]
|
||||||
[COLOR green][B]Canales agregados y arreglos[/B][/COLOR]
|
[COLOR green][B]Canales agregados y arreglos[/B][/COLOR]
|
||||||
[I]- Cinecalidad
|
[I]- Elitetorrent
|
||||||
- Cinefox
|
- Seriespapaya
|
||||||
- Mundoflv
|
- Newpct1 -- [COLOR red]Momentáneamente búsqueda deshabilitada[/COLOR][/I][CR]
|
||||||
- Metaserie
|
[COLOR green][B]Arreglos internos[/B][/COLOR]
|
||||||
- Pelisplanet
|
[I]- videolibrary_service -- ahora no actualiza una serie de un canal, si está desactivado[/I]
|
||||||
- flashx
|
|
||||||
- xTheatre
|
|
||||||
- Playpornx[/I][CR]
|
|
||||||
[COLOR green][B]Servidores agregados y arreglos[/B][/COLOR][CR]
|
|
||||||
[I]- Flashx
|
|
||||||
- Streamcherry[/I]
|
|
||||||
|
|
||||||
|
|
||||||
</news>
|
</news>
|
||||||
<description lang="es">Descripción en Español</description>
|
<description lang="es">Descripción en Español</description>
|
||||||
<summary lang="en">English summary</summary>
|
<summary lang="en">English summary</summary>
|
||||||
|
|||||||
Executable → Regular
+30
-25
@@ -18,7 +18,7 @@ def mainlist(item):
|
|||||||
extra="peliculas"))
|
extra="peliculas"))
|
||||||
itemlist.append(
|
itemlist.append(
|
||||||
Item(channel=item.channel, action="submenu", title="Series", url="http://www.newpct1.com/", extra="series"))
|
Item(channel=item.channel, action="submenu", title="Series", url="http://www.newpct1.com/", extra="series"))
|
||||||
itemlist.append(Item(channel=item.channel, action="search", title="Buscar"))
|
# itemlist.append(Item(channel=item.channel, action="search", title="Buscar"))
|
||||||
|
|
||||||
return itemlist
|
return itemlist
|
||||||
|
|
||||||
@@ -57,7 +57,7 @@ def submenu(item):
|
|||||||
data = re.sub(r"\n|\r|\t|\s{2}|(<!--.*?-->)", "", httptools.downloadpage(item.url).data)
|
data = re.sub(r"\n|\r|\t|\s{2}|(<!--.*?-->)", "", httptools.downloadpage(item.url).data)
|
||||||
data = unicode(data, "iso-8859-1", errors="replace").encode("utf-8")
|
data = unicode(data, "iso-8859-1", errors="replace").encode("utf-8")
|
||||||
|
|
||||||
patron = '<li><a href="http://www.newpct1.com/' + item.extra + '/">.*?<ul>(.*?)</ul>'
|
patron = '<li><a href="http://(?:www.)?newpct1.com/' + item.extra + '/">.*?<ul>(.*?)</ul>'
|
||||||
data = scrapertools.get_match(data, patron)
|
data = scrapertools.get_match(data, patron)
|
||||||
|
|
||||||
patron = '<a href="([^"]+)".*?>([^>]+)</a>'
|
patron = '<a href="([^"]+)".*?>([^>]+)</a>'
|
||||||
@@ -126,7 +126,6 @@ def listado(item):
|
|||||||
if "1.com/series" in url:
|
if "1.com/series" in url:
|
||||||
action = "completo"
|
action = "completo"
|
||||||
extra = "serie"
|
extra = "serie"
|
||||||
context = "tvshow"
|
|
||||||
|
|
||||||
title = scrapertools.find_single_match(title, '([^-]+)')
|
title = scrapertools.find_single_match(title, '([^-]+)')
|
||||||
title = title.replace("Ver online", "", 1).replace("Descarga Serie HD", "", 1).replace("Ver en linea", "",
|
title = title.replace("Ver online", "", 1).replace("Descarga Serie HD", "", 1).replace("Ver en linea", "",
|
||||||
@@ -137,7 +136,7 @@ def listado(item):
|
|||||||
url_i = 'http://www.newpct1.com/index.php?page=buscar&url=&letter=&q=%22' + title.replace(" ","%20") + '%22'
|
url_i = 'http://www.newpct1.com/index.php?page=buscar&url=&letter=&q=%22' + title.replace(" ","%20") + '%22'
|
||||||
else:
|
else:
|
||||||
url_i = 'http://www.newpct1.com/index.php?page=buscar&url=&letter=&q=' + title
|
url_i = 'http://www.newpct1.com/index.php?page=buscar&url=&letter=&q=' + title
|
||||||
|
|
||||||
if "1.com/series-hd" in url:
|
if "1.com/series-hd" in url:
|
||||||
extra="serie-hd"
|
extra="serie-hd"
|
||||||
url = url_i + '&categoryID=&categoryIDR=1469&calidad=' + calidad.replace(" ","+") #DTV+720p+AC3+5.1
|
url = url_i + '&categoryID=&categoryIDR=1469&calidad=' + calidad.replace(" ","+") #DTV+720p+AC3+5.1
|
||||||
@@ -147,29 +146,31 @@ def listado(item):
|
|||||||
elif "1.com/series/" in url:
|
elif "1.com/series/" in url:
|
||||||
extra="serie-tv"
|
extra="serie-tv"
|
||||||
url = url_i + '&categoryID=&categoryIDR=767&calidad=' + calidad.replace(" ","+")
|
url = url_i + '&categoryID=&categoryIDR=767&calidad=' + calidad.replace(" ","+")
|
||||||
|
|
||||||
url += '&idioma=&ordenar=Nombre&inon=Descendente'
|
url += '&idioma=&ordenar=Nombre&inon=Descendente'
|
||||||
'''
|
'''
|
||||||
show = title
|
|
||||||
else:
|
else:
|
||||||
title = title.replace("Descargar", "", 1).strip()
|
title = title.replace("Descargar", "", 1).strip()
|
||||||
if title.endswith("gratis"): title = title[:-7]
|
if title.endswith("gratis"): title = title[:-7]
|
||||||
show = ""
|
|
||||||
context = "movie"
|
|
||||||
|
|
||||||
context_title = scrapertools.find_single_match(url, "http://www.newpct1.com/(.*?)/(.*?)/")
|
show = title
|
||||||
|
if item.extra != "buscar-list":
|
||||||
|
title = title + ' ' + calidad
|
||||||
|
|
||||||
|
context = ""
|
||||||
|
context_title = scrapertools.find_single_match(url, "http://(?:www.)?newpct1.com/(.*?)/(.*?)/")
|
||||||
if context_title:
|
if context_title:
|
||||||
try:
|
try:
|
||||||
|
context = context_title[0].replace("pelicula", "movie").replace("descargar", "movie").replace("series",
|
||||||
|
"tvshow")
|
||||||
context_title = context_title[1].replace("-", " ")
|
context_title = context_title[1].replace("-", " ")
|
||||||
if re.search('\d{4}', context_title[-4:]):
|
if re.search('\d{4}', context_title[-4:]):
|
||||||
context_title = context_title[:-4]
|
context_title = context_title[:-4]
|
||||||
elif re.search('\(\d{4}\)', context_title[-6:]):
|
elif re.search('\(\d{4}\)', context_title[-6:]):
|
||||||
context_title = context_title[:-6]
|
context_title = context_title[:-6]
|
||||||
except:
|
|
||||||
context_title = title
|
|
||||||
|
|
||||||
if item.extra != "buscar-list":
|
except:
|
||||||
title = title + ' ' + calidad
|
context_title = show
|
||||||
|
|
||||||
itemlist.append(
|
itemlist.append(
|
||||||
Item(channel=item.channel, action=action, title=title, url=url, thumbnail=thumbnail, extra=extra, show=show,
|
Item(channel=item.channel, action=action, title=title, url=url, thumbnail=thumbnail, extra=extra, show=show,
|
||||||
@@ -212,7 +213,7 @@ def completo(item):
|
|||||||
categoryID=buscar_en_subcategoria(item.show,'767')
|
categoryID=buscar_en_subcategoria(item.show,'767')
|
||||||
if categoryID !="":
|
if categoryID !="":
|
||||||
item.url=item.url.replace("categoryID=","categoryID="+categoryID)
|
item.url=item.url.replace("categoryID=","categoryID="+categoryID)
|
||||||
|
|
||||||
#Fanart
|
#Fanart
|
||||||
oTvdb= TvDb()
|
oTvdb= TvDb()
|
||||||
serieID=oTvdb.get_serieId_by_title(item.show)
|
serieID=oTvdb.get_serieId_by_title(item.show)
|
||||||
@@ -241,12 +242,12 @@ def completo(item):
|
|||||||
salir = False
|
salir = False
|
||||||
while not salir:
|
while not salir:
|
||||||
|
|
||||||
# Saca la URL de la siguiente página
|
# Saca la URL de la siguiente página
|
||||||
ultimo_item = items_programas[len(items_programas) - 1]
|
ultimo_item = items_programas[len(items_programas) - 1]
|
||||||
|
|
||||||
# Páginas intermedias
|
# Páginas intermedias
|
||||||
if ultimo_item.action == ultimo_action:
|
if ultimo_item.action == ultimo_action:
|
||||||
# Quita el elemento de "Página siguiente"
|
# Quita el elemento de "Página siguiente"
|
||||||
ultimo_item = items_programas.pop()
|
ultimo_item = items_programas.pop()
|
||||||
|
|
||||||
# Añade las entradas de la página a la lista completa
|
# Añade las entradas de la página a la lista completa
|
||||||
@@ -269,7 +270,7 @@ def completo(item):
|
|||||||
salir = True
|
salir = True
|
||||||
|
|
||||||
if (config.get_videolibrary_support() and len(itemlist) > 0 and item.extra.startswith("serie")):
|
if (config.get_videolibrary_support() and len(itemlist) > 0 and item.extra.startswith("serie")):
|
||||||
itemlist.append(Item(channel=item.channel, title="Añadir esta serie a la videoteca", url=item.url,
|
itemlist.append(Item(channel=item.channel, title="Añadir esta serie a la biblioteca", url=item.url,
|
||||||
action="add_serie_to_library", extra="completo###serie_add", show=item.show))
|
action="add_serie_to_library", extra="completo###serie_add", show=item.show))
|
||||||
logger.debug("items=" + str(len(itemlist)))
|
logger.debug("items=" + str(len(itemlist)))
|
||||||
return itemlist
|
return itemlist
|
||||||
@@ -421,6 +422,8 @@ def findvideos(item):
|
|||||||
Item(channel=item.channel, action="play", server="torrent", title=title + " [torrent]", fulltitle=title,
|
Item(channel=item.channel, action="play", server="torrent", title=title + " [torrent]", fulltitle=title,
|
||||||
url=url, thumbnail=caratula, plot=item.plot, folder=False))
|
url=url, thumbnail=caratula, plot=item.plot, folder=False))
|
||||||
|
|
||||||
|
|
||||||
|
logger.debug("matar %s" % data)
|
||||||
# escraped ver vídeos, descargar vídeos un link, múltiples liks
|
# escraped ver vídeos, descargar vídeos un link, múltiples liks
|
||||||
data = data.replace("'", '"')
|
data = data.replace("'", '"')
|
||||||
data = data.replace(
|
data = data.replace(
|
||||||
@@ -447,11 +450,12 @@ def findvideos(item):
|
|||||||
for logo, servidor, idioma, calidad, enlace, titulo in enlaces_ver:
|
for logo, servidor, idioma, calidad, enlace, titulo in enlaces_ver:
|
||||||
servidor = servidor.replace("streamin", "streaminto")
|
servidor = servidor.replace("streamin", "streaminto")
|
||||||
titulo = titulo + " [" + servidor + "]"
|
titulo = titulo + " [" + servidor + "]"
|
||||||
if servertools.is_server_enabled(servidor):
|
mostrar_server = True
|
||||||
|
if config.get_setting("hidepremium"):
|
||||||
|
mostrar_server = servertools.is_server_enabled(servidor)
|
||||||
|
if mostrar_server:
|
||||||
try:
|
try:
|
||||||
servers_module = __import__("servers." + servidor)
|
devuelve = servertools.findvideosbyserver(enlace, servidor)
|
||||||
server_module = getattr(servers_module, servidor)
|
|
||||||
devuelve = server_module.find_videos(enlace)
|
|
||||||
if devuelve:
|
if devuelve:
|
||||||
enlace = devuelve[0][1]
|
enlace = devuelve[0][1]
|
||||||
itemlist.append(
|
itemlist.append(
|
||||||
@@ -467,11 +471,12 @@ def findvideos(item):
|
|||||||
for enlace in partes:
|
for enlace in partes:
|
||||||
parte_titulo = titulo + " (%s/%s)" % (p, len(partes)) + " [" + servidor + "]"
|
parte_titulo = titulo + " (%s/%s)" % (p, len(partes)) + " [" + servidor + "]"
|
||||||
p += 1
|
p += 1
|
||||||
if servertools.is_server_enabled(servidor):
|
mostrar_server = True
|
||||||
|
if config.get_setting("hidepremium"):
|
||||||
|
mostrar_server = servertools.is_server_enabled(servidor)
|
||||||
|
if mostrar_server:
|
||||||
try:
|
try:
|
||||||
servers_module = __import__("servers." + servidor)
|
devuelve = servertools.findvideosbyserver(enlace, servidor)
|
||||||
server_module = getattr(servers_module, servidor)
|
|
||||||
devuelve = server_module.find_videos(enlace)
|
|
||||||
if devuelve:
|
if devuelve:
|
||||||
enlace = devuelve[0][1]
|
enlace = devuelve[0][1]
|
||||||
itemlist.append(Item(fanart=item.fanart, channel=item.channel, action="play", server=servidor,
|
itemlist.append(Item(fanart=item.fanart, channel=item.channel, action="play", server=servidor,
|
||||||
|
|||||||
Executable → Regular
+23
-24
@@ -6,7 +6,6 @@ import urllib
|
|||||||
import urlparse
|
import urlparse
|
||||||
|
|
||||||
from channels import filtertools
|
from channels import filtertools
|
||||||
from channelselector import get_thumb
|
|
||||||
from core import config
|
from core import config
|
||||||
from core import httptools
|
from core import httptools
|
||||||
from core import jsontools
|
from core import jsontools
|
||||||
@@ -25,9 +24,9 @@ CALIDADES = ['360p', '480p', '720p HD', '1080p HD']
|
|||||||
def mainlist(item):
|
def mainlist(item):
|
||||||
logger.info()
|
logger.info()
|
||||||
|
|
||||||
thumb_series = get_thumb("thumb_channels_tvshow.png")
|
thumb_series = config.get_thumb("thumb_channels_tvshow.png")
|
||||||
thumb_series_az = get_thumb("thumb_channels_tvshow_az.png")
|
thumb_series_az = config.get_thumb("thumb_channels_tvshow_az.png")
|
||||||
thumb_buscar = get_thumb("thumb_search.png")
|
thumb_buscar = config.get_thumb("thumb_search.png")
|
||||||
|
|
||||||
itemlist = []
|
itemlist = []
|
||||||
itemlist.append(
|
itemlist.append(
|
||||||
@@ -52,22 +51,22 @@ def listado_alfabetico(item):
|
|||||||
|
|
||||||
|
|
||||||
def series_por_letra(item):
|
def series_por_letra(item):
|
||||||
logger.info("letra: {0}".format(item.title))
|
logger.info("letra: %s" % item.title)
|
||||||
item.letter = item.title.lower()
|
item.letter = item.title.lower()
|
||||||
item.extra = 0
|
item.extra = 0
|
||||||
return series_por_letra_y_grupo(item)
|
return series_por_letra_y_grupo(item)
|
||||||
|
|
||||||
|
|
||||||
def series_por_letra_y_grupo(item):
|
def series_por_letra_y_grupo(item):
|
||||||
logger.info("letra: {0} - grupo: {1}".format(item.letter, item.extra))
|
logger.info("letra: %s - grupo: %s" % (item.letter, item.extra))
|
||||||
itemlist = []
|
itemlist = []
|
||||||
url = urlparse.urljoin(HOST, "autoload_process.php")
|
url = urlparse.urljoin(HOST, "autoload_process.php")
|
||||||
|
|
||||||
postRequest = {
|
post_request = {
|
||||||
"group_no": item.extra,
|
"group_no": item.extra,
|
||||||
"letra": item.letter.lower()
|
"letra": item.letter.lower()
|
||||||
}
|
}
|
||||||
data = httptools.downloadpage(url, post=urllib.urlencode(postRequest)).data
|
data = httptools.downloadpage(url, post=urllib.urlencode(post_request)).data
|
||||||
|
|
||||||
series = re.findall(
|
series = re.findall(
|
||||||
'list_imagen.+?src="(?P<img>[^"]+).+?<div class="list_titulo"><a[^>]+href="(?P<url>[^"]+)[^>]+>(.*?)</a>', data,
|
'list_imagen.+?src="(?P<img>[^"]+).+?<div class="list_titulo"><a[^>]+href="(?P<url>[^"]+)[^>]+>(.*?)</a>', data,
|
||||||
@@ -107,7 +106,7 @@ def novedades(item):
|
|||||||
|
|
||||||
|
|
||||||
def newest(categoria):
|
def newest(categoria):
|
||||||
logger.info("categoria: {0}".format(categoria))
|
logger.info("categoria: %s" % categoria)
|
||||||
|
|
||||||
if categoria != 'series':
|
if categoria != 'series':
|
||||||
return []
|
return []
|
||||||
@@ -119,13 +118,13 @@ def newest(categoria):
|
|||||||
except:
|
except:
|
||||||
import sys
|
import sys
|
||||||
for line in sys.exc_info():
|
for line in sys.exc_info():
|
||||||
logger.error("{0}".format(line))
|
logger.error("%s" % line)
|
||||||
|
|
||||||
return []
|
return []
|
||||||
|
|
||||||
|
|
||||||
def episodios(item):
|
def episodios(item):
|
||||||
logger.info("url: {0}".format(item.url))
|
logger.info("url: %s" % item.url)
|
||||||
|
|
||||||
data = httptools.downloadpage(item.url).data
|
data = httptools.downloadpage(item.url).data
|
||||||
|
|
||||||
@@ -136,15 +135,15 @@ def episodios(item):
|
|||||||
for url, title, langs in episodes:
|
for url, title, langs in episodes:
|
||||||
logger.debug("langs %s" % langs)
|
logger.debug("langs %s" % langs)
|
||||||
languages = " ".join(
|
languages = " ".join(
|
||||||
["[{0}]".format(IDIOMAS.get(lang, lang)) for lang in re.findall('images/s-([^\.]+)', langs)])
|
["[%s]" % IDIOMAS.get(lang, lang) for lang in re.findall('images/s-([^\.]+)', langs)])
|
||||||
filter_lang = languages.replace("[", "").replace("]", "").split(" ")
|
filter_lang = languages.replace("[", "").replace("]", "").split(" ")
|
||||||
itemlist.append(item.clone(action="findvideos",
|
itemlist.append(item.clone(action="findvideos",
|
||||||
title="{0} {1} {2}".format(item.title, title, languages),
|
title="%s %s %s" % (item.title, title, languages),
|
||||||
url=urlparse.urljoin(HOST, url),
|
url=urlparse.urljoin(HOST, url),
|
||||||
language=filter_lang
|
language=filter_lang
|
||||||
))
|
))
|
||||||
|
|
||||||
itemlist = filtertools.get_links(itemlist, item.channel, list_idiomas, CALIDADES)
|
itemlist = filtertools.get_links(itemlist, item, list_idiomas, CALIDADES)
|
||||||
|
|
||||||
# Opción "Añadir esta serie a la videoteca de XBMC"
|
# Opción "Añadir esta serie a la videoteca de XBMC"
|
||||||
if config.get_videolibrary_support() and len(itemlist) > 0:
|
if config.get_videolibrary_support() and len(itemlist) > 0:
|
||||||
@@ -155,10 +154,10 @@ def episodios(item):
|
|||||||
|
|
||||||
|
|
||||||
def search(item, texto):
|
def search(item, texto):
|
||||||
logger.info("texto: {0}".format(texto))
|
logger.info("texto: %s" % texto)
|
||||||
data = httptools.downloadpage(urlparse.urljoin(HOST, "/buscar.php?term={0}".format(texto))).data
|
data = httptools.downloadpage(urlparse.urljoin(HOST, "/buscar.php?term=%s" % texto)).data
|
||||||
jsonResult = jsontools.load(data)
|
data_dict = jsontools.load(data)
|
||||||
tvShows = jsonResult["myData"]
|
tvshows = data_dict["myData"]
|
||||||
|
|
||||||
return [item.clone(action="episodios",
|
return [item.clone(action="episodios",
|
||||||
title=show["titulo"],
|
title=show["titulo"],
|
||||||
@@ -166,11 +165,11 @@ def search(item, texto):
|
|||||||
url=urlparse.urljoin(HOST, show["urla"]),
|
url=urlparse.urljoin(HOST, show["urla"]),
|
||||||
thumbnail=urlparse.urljoin(HOST, show["img"]),
|
thumbnail=urlparse.urljoin(HOST, show["img"]),
|
||||||
context=filtertools.context(item, list_idiomas, CALIDADES)
|
context=filtertools.context(item, list_idiomas, CALIDADES)
|
||||||
) for show in tvShows]
|
) for show in tvshows]
|
||||||
|
|
||||||
|
|
||||||
def findvideos(item):
|
def findvideos(item):
|
||||||
logger.info("url: {0}".format(item.url))
|
logger.info("url: %s" % item.url)
|
||||||
|
|
||||||
data = httptools.downloadpage(item.url).data
|
data = httptools.downloadpage(item.url).data
|
||||||
|
|
||||||
@@ -204,9 +203,9 @@ def findvideos(item):
|
|||||||
|
|
||||||
|
|
||||||
def play(item):
|
def play(item):
|
||||||
logger.info("play: {0}".format(item.url))
|
logger.info("play: %s" % item.url)
|
||||||
data = httptools.downloadpage(item.url).data
|
data = httptools.downloadpage(item.url).data
|
||||||
videoURL = scrapertools.find_single_match(data, "location.href='([^']+)")
|
video_url = scrapertools.find_single_match(data, "location.href='([^']+)")
|
||||||
logger.debug("Video URL = {0}".format(videoURL))
|
logger.debug("Video URL = %s" % video_url)
|
||||||
itemlist = servertools.find_video_items(data=videoURL)
|
itemlist = servertools.find_video_items(data=video_url)
|
||||||
return itemlist
|
return itemlist
|
||||||
|
|||||||
Executable → Regular
+33
-26
@@ -24,41 +24,48 @@ def update(path, p_dialog, i, t, serie, overwrite):
|
|||||||
serie.channel = channel
|
serie.channel = channel
|
||||||
serie.url = url
|
serie.url = url
|
||||||
|
|
||||||
heading = 'Actualizando videoteca....'
|
channel_active = config.get_setting("active", channel=channel, default=False)
|
||||||
p_dialog.update(int(math.ceil((i + 1) * t)), heading, "%s: %s" % (serie.contentSerieName,
|
|
||||||
serie.channel.capitalize()))
|
|
||||||
try:
|
|
||||||
pathchannels = filetools.join(config.get_runtime_path(), "channels", serie.channel + '.py')
|
|
||||||
logger.info("Cargando canal: " + pathchannels + " " +
|
|
||||||
serie.channel)
|
|
||||||
|
|
||||||
if serie.library_filter_show:
|
if channel_active:
|
||||||
serie.show = serie.library_filter_show.get(channel, serie.contentSerieName)
|
|
||||||
|
|
||||||
obj = imp.load_source(serie.channel, pathchannels)
|
|
||||||
itemlist = obj.episodios(serie)
|
|
||||||
|
|
||||||
|
heading = 'Actualizando videoteca....'
|
||||||
|
p_dialog.update(int(math.ceil((i + 1) * t)), heading, "%s: %s" % (serie.contentSerieName,
|
||||||
|
serie.channel.capitalize()))
|
||||||
try:
|
try:
|
||||||
if int(overwrite) == 3:
|
pathchannels = filetools.join(config.get_runtime_path(), "channels", serie.channel + '.py')
|
||||||
# Sobrescribir todos los archivos (tvshow.nfo, 1x01.nfo, 1x01 [canal].json, 1x01.strm, etc...)
|
logger.info("Cargando canal: " + pathchannels + " " +
|
||||||
insertados, sobreescritos, fallidos = videolibrarytools.save_tvshow(serie, itemlist)
|
serie.channel)
|
||||||
else:
|
|
||||||
insertados, sobreescritos, fallidos = videolibrarytools.save_episodes(path, itemlist, serie,
|
if serie.library_filter_show:
|
||||||
silent=True,
|
serie.show = serie.library_filter_show.get(channel, serie.contentSerieName)
|
||||||
overwrite=overwrite)
|
|
||||||
insertados_total += insertados
|
obj = imp.load_source(serie.channel, pathchannels)
|
||||||
|
itemlist = obj.episodios(serie)
|
||||||
|
|
||||||
|
try:
|
||||||
|
if int(overwrite) == 3:
|
||||||
|
# Sobrescribir todos los archivos (tvshow.nfo, 1x01.nfo, 1x01 [canal].json, 1x01.strm, etc...)
|
||||||
|
insertados, sobreescritos, fallidos = videolibrarytools.save_tvshow(serie, itemlist)
|
||||||
|
else:
|
||||||
|
insertados, sobreescritos, fallidos = videolibrarytools.save_episodes(path, itemlist, serie,
|
||||||
|
silent=True,
|
||||||
|
overwrite=overwrite)
|
||||||
|
insertados_total += insertados
|
||||||
|
|
||||||
|
except Exception, ex:
|
||||||
|
logger.error("Error al guardar los capitulos de la serie")
|
||||||
|
template = "An exception of type %s occured. Arguments:\n%r"
|
||||||
|
message = template % (type(ex).__name__, ex.args)
|
||||||
|
logger.error(message)
|
||||||
|
|
||||||
except Exception, ex:
|
except Exception, ex:
|
||||||
logger.error("Error al guardar los capitulos de la serie")
|
logger.error("Error al obtener los episodios de: %s" % serie.show)
|
||||||
template = "An exception of type %s occured. Arguments:\n%r"
|
template = "An exception of type %s occured. Arguments:\n%r"
|
||||||
message = template % (type(ex).__name__, ex.args)
|
message = template % (type(ex).__name__, ex.args)
|
||||||
logger.error(message)
|
logger.error(message)
|
||||||
|
|
||||||
except Exception, ex:
|
else:
|
||||||
logger.error("Error al obtener los episodios de: %s" % serie.show)
|
logger.debug("Canal %s no activo no se actualiza" % serie.channel)
|
||||||
template = "An exception of type %s occured. Arguments:\n%r"
|
|
||||||
message = template % (type(ex).__name__, ex.args)
|
|
||||||
logger.error(message)
|
|
||||||
|
|
||||||
return insertados_total > 0
|
return insertados_total > 0
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user