From f7a4a67191317197e706dc09ec9035f61987fffb Mon Sep 17 00:00:00 2001 From: Kingbox <37674310+lopezvg@users.noreply.github.com> Date: Wed, 10 Oct 2018 19:06:36 +0200 Subject: [PATCH] Mitorrents y Tiotorrent: borrado por desactualizados --- plugin.video.alfa/channels/miltorrents.json | 32 -- plugin.video.alfa/channels/miltorrents.py | 447 -------------------- plugin.video.alfa/channels/tiotorrent.json | 33 -- plugin.video.alfa/channels/tiotorrent.py | 343 --------------- 4 files changed, 855 deletions(-) delete mode 100755 plugin.video.alfa/channels/miltorrents.json delete mode 100755 plugin.video.alfa/channels/miltorrents.py delete mode 100644 plugin.video.alfa/channels/tiotorrent.json delete mode 100644 plugin.video.alfa/channels/tiotorrent.py diff --git a/plugin.video.alfa/channels/miltorrents.json b/plugin.video.alfa/channels/miltorrents.json deleted file mode 100755 index 08451d36..00000000 --- a/plugin.video.alfa/channels/miltorrents.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "id": "miltorrents", - "name": "Miltorrents", - "active": false, - "adult": false, - "language": ["cast"], - "thumbnail": "http://imgur.com/KZoska0.png", - "banner": "miltorrents.png", - "categories": [ - "torrent", - "movie", - "tvshow" - ], - "settings": [ - { - "id": "include_in_global_search", - "type": "bool", - "label": "Incluir en busqueda global", - "default": true, - "enabled": true, - "visible": true - }, - { - "id": "include_in_newest_torrent", - "type": "bool", - "label": "Incluir en Novedades - Torrent", - "default": true, - "enabled": true, - "visible": true - } - ] -} \ No newline at end of file diff --git a/plugin.video.alfa/channels/miltorrents.py b/plugin.video.alfa/channels/miltorrents.py deleted file mode 100755 index 68a2d154..00000000 --- a/plugin.video.alfa/channels/miltorrents.py +++ /dev/null @@ -1,447 +0,0 @@ -# -*- coding: utf-8 -*- - -import math -import os -import re -import unicodedata -import urllib - -from core import httptools -from core import scrapertools -from core import tmdb -from core.item import Item -from core.scrapertools import decodeHtmlentities as dhe -from platformcode import config, logger -from channelselector import get_thumb - - -def mainlist(item): - logger.info() - check_bg = item.action - - if str(check_bg) == "": - check_bg = "bglobal" - itemlist = [] - - itemlist.append(Item(channel=item.channel, title="[COLOR yellow][B]Películas[/B][/COLOR]", action="peliculas", - url="http://www.miltorrents.com", thumbnail=get_thumb('movies', auto=True), - fanart="http://imgur.com/y4nJyZh.jpg")) - title = "[COLOR firebrick][B]Buscar[/B][/COLOR]" + " " + "[COLOR yellow][B]Peliculas[/B][/COLOR]" - itemlist.append(Item(channel=item.channel, title=" " + title, action="search", url="", - thumbnail=get_thumb('search', auto=True), fanart="http://imgur.com/gwjawWV.jpg", - extra="peliculas" + "|" + check_bg)) - - itemlist.append(Item(channel=item.channel, title="[COLOR slategray][B]Series[/B][/COLOR]", action="peliculas", - url="http://www.miltorrents.com/series", thumbnail=get_thumb('tvshows', auto=True), - fanart="http://imgur.com/LwS32zX.jpg")) - - title = "[COLOR firebrick][B]Buscar[/B][/COLOR]" + " " + "[COLOR slategray][B]Series[/B][/COLOR]" - itemlist.append(Item(channel=item.channel, title=" " + title, action="search", url="", - thumbnail=get_thumb('search', auto=True), fanart="http://imgur.com/ecPmzDj.jpg", - extra="series" + "|" + check_bg)) - - return itemlist - -def search(item, texto): - logger.info() - texto = texto.replace(" ", "+") - if item.extra: - if item.extra.split("|")[0] == "series": - item.url = "http://www.miltorrents.com/series/?pTit=%s&pOrd=FE" % (texto) - else: - item.url = "http://www.miltorrents.com/?pTit=%s&pOrd=FE" % (texto) - - item.extra = "search" + "|" + item.extra.split("|")[1] + "|" + texto - - try: - return peliculas(item) - # Se captura la excepciÛn, para no interrumpir al buscador global si un canal falla - except: - import sys - for line in sys.exc_info(): - logger.error("%s" % line) - return [] - else: - if item.contentType != "movie": - item.url = "http://www.miltorrents.com/series/?pTit=%s&pOrd=FE" % (texto) - check_sp = "tvshow" - else: - item.url = "http://www.miltorrents.com/?pTit=%s&pOrd=FE" % (texto) - check_sp = "peliculas" - item.extra = "search" + "|""bglobal" + "|" + texto + "|" + check_sp - try: - return peliculas(item) - # Se captura la excepciÛn, para no interrumpir al buscador global si un canal falla - except: - import sys - for line in sys.exc_info(): - logger.error("%s" % line) - return [] - -def peliculas(item): - logger.info() - itemlist = [] - data = httptools.downloadpage(item.url).data - data = re.sub(r"Independance", "Independence", data) - if "serie" in item.url: - patron = '
(.*?)<\/div>.*?(.*?)([^<]+)\((\d\d\d\d)\)' - matches = re.compile(patron, re.DOTALL).findall(data) - for p_rating, url, thumbnail, title, year in matches: - - try: - rating = scrapertools.get_match(p_rating, '
(.*?)= 5 and int(check_rating) < 8: - rating = "[COLOR springgreen][B]" + rating + "[/B][/COLOR]" - elif int(check_rating) >= 8 and int(check_rating) < 10: - rating = "[COLOR yellow][B]" + rating + "[/B][/COLOR]" - elif int(check_rating) == 10: - rating = "[COLOR orangered][B]" + rating + "[/B][/COLOR]" - else: - rating = "[COLOR crimson][B]" + rating + "[/B][/COLOR]" - except: - rating = "[COLOR crimson][B]" + rating + "[/B][/COLOR]" - if "10." in rating: - rating = re.sub(r'10\.\d+', '10', rating) - title_f = "[COLOR gold][B]" + title + "[/B][/COLOR]" + " " + rating - trailer = title_fan + " " + "trailer" - trailer = urllib.quote(trailer) - extra = trailer + "|" + title_fan + "|" + year + "|" + "pelicula" - itemlist.append(Item(channel=item.channel, title=title_f, url=url, action="findvideos", thumbnail=thumbnail, - fanart="http://imgur.com/Oi1mlFn.jpg", extra=extra, folder=True, contentTitle= title, infoLabels={'year':year})) - tmdb.set_infoLabels_itemlist(itemlist, seekTmdb=True) - ## Paginación - patronvideos = '