eurostreaming e fix vari su altadefinizione01_L, fix wstream, add servers vari (#47)
* eurostreaming by support e fix * fix wstream * aggiunto servers turbovid * server nowvideo * in channelselector aggiunta una voce e fix vari * fix support per episode * fix title2 cleahtml * fix per speedvideo * fix cinemalibero aggiunta configurazione canale per cambio host automatico * fix support item.language * migliorie codice server deltabit turbobit
This commit is contained in:
@@ -10,7 +10,8 @@
|
||||
"fix" : "reimpostato url e modificato file per KOD",
|
||||
"change_date": "2019-30-04",
|
||||
"categories": [
|
||||
"movie"
|
||||
"movie",
|
||||
"vosi"
|
||||
],
|
||||
"settings": [
|
||||
{
|
||||
@@ -30,7 +31,7 @@
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "include_in_newest_film",
|
||||
"id": "include_in_newest_peliculas",
|
||||
"type": "bool",
|
||||
"label": "Includi in Novità",
|
||||
"default": true,
|
||||
@@ -79,7 +80,8 @@
|
||||
"visible": true,
|
||||
"lvalues": [
|
||||
"Non filtrare",
|
||||
"IT"
|
||||
"ITA",
|
||||
"vosi"
|
||||
]
|
||||
},
|
||||
{
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# -*- Channel Altadefinizione01L Film - Serie -*-
|
||||
# -*- Creato per Alfa-addon -*-
|
||||
# -*- e adattato for KOD -*-
|
||||
# -*- By Greko -*-
|
||||
# -*- last change: 26/05/2019
|
||||
|
||||
import channelselector
|
||||
from specials import autoplay
|
||||
@@ -18,10 +15,7 @@ __channel__ = "altadefinizione01_link"
|
||||
list_servers = ['supervideo', 'streamcherry','rapidvideo', 'streamango', 'openload']
|
||||
list_quality = ['default']
|
||||
|
||||
#host = config.get_setting("channel_host", __channel__)
|
||||
host = config.get_channel_url(__channel__)
|
||||
checklinks = config.get_setting('checklinks', __channel__)
|
||||
checklinks_number = config.get_setting('checklinks_number', __channel__)
|
||||
host = config.get_setting("channel_host", __channel__)
|
||||
|
||||
headers = [['Referer', host]]
|
||||
# =========== home menu ===================
|
||||
@@ -156,7 +150,5 @@ def findvideos(item):
|
||||
|
||||
# Requerido para AutoPlay
|
||||
autoplay.start(itemlist, item)
|
||||
|
||||
support.videolibrary(itemlist, item, 'color kod')
|
||||
|
||||
return itemlist
|
||||
|
||||
@@ -8,6 +8,14 @@
|
||||
"banner": "https://www.cinemalibero.center/wp-content/themes/Cinemalibero%202.0/images/logo02.png",
|
||||
"categories": ["tvshow", "movie","anime"],
|
||||
"settings": [
|
||||
{
|
||||
"id": "channel_host",
|
||||
"type": "text",
|
||||
"label": "Host del canale",
|
||||
"default": "https://www.cinemalibero.fun/",
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "include_in_global_search",
|
||||
"type": "bool",
|
||||
|
||||
@@ -11,6 +11,7 @@ from lib import unshortenit
|
||||
from platformcode import config
|
||||
from platformcode import logger
|
||||
from specials import autoplay
|
||||
import channelselector
|
||||
|
||||
# Necessario per Autoplay
|
||||
IDIOMAS = {'Italiano': 'IT'}
|
||||
@@ -24,10 +25,9 @@ checklinks_number = config.get_setting('checklinks_number', 'cinemalibero')
|
||||
|
||||
__channel__ = "cinemalibero"
|
||||
host = config.get_channel_url(__channel__)
|
||||
|
||||
headers = [['Referer', host]]
|
||||
|
||||
|
||||
|
||||
def mainlist(item):
|
||||
logger.info('[cinemalibero.py] mainlist')
|
||||
|
||||
@@ -44,6 +44,15 @@ def mainlist(item):
|
||||
support.menu(itemlist, 'Sport bold', 'video', host+'/category/sport/')
|
||||
|
||||
autoplay.show_option(item.channel, itemlist) # Necessario per Autoplay (Menu Configurazione)
|
||||
|
||||
itemlist.append(
|
||||
Item(channel='setting',
|
||||
action="channel_config",
|
||||
title=support.typo("Configurazione Canale color lime"),
|
||||
config=item.channel,
|
||||
folder=False,
|
||||
thumbnail=channelselector.get_thumb('setting_0.png'))
|
||||
)
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
@@ -6,8 +6,16 @@
|
||||
"language": ["ita"],
|
||||
"thumbnail": "https://eurostreaming.cafe/wp-content/uploads/2017/08/logocafe.png",
|
||||
"bannermenu": "https://eurostreaming.cafe/wp-content/uploads/2017/08/logocafe.png",
|
||||
"categories": ["tvshow","anime"],
|
||||
"categories": ["tvshow","anime","vosi"],
|
||||
"settings": [
|
||||
{
|
||||
"id": "channel_host",
|
||||
"type": "text",
|
||||
"label": "Host del canale",
|
||||
"default": "https://eurostreaming.cafe/",
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "include_in_global_search",
|
||||
"type": "bool",
|
||||
@@ -16,14 +24,6 @@
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "modo_grafico",
|
||||
"type": "bool",
|
||||
"label": "Cerca informazioni extra",
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "include_in_newest_series",
|
||||
"type": "bool",
|
||||
@@ -39,23 +39,6 @@
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "checklinks",
|
||||
"type": "bool",
|
||||
"label": "Verifica se i link esistono",
|
||||
"default": true,
|
||||
"enabled": true,
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"id": "checklinks_number",
|
||||
"type": "list",
|
||||
"label": "Numero de link da verificare",
|
||||
"default": 1,
|
||||
"enabled": true,
|
||||
"visible": "eq(-1,true)",
|
||||
"lvalues": [ "5", "10", "15", "20" ]
|
||||
},
|
||||
{
|
||||
"id": "filter_languages",
|
||||
@@ -66,25 +49,9 @@
|
||||
"visible": true,
|
||||
"lvalues": [
|
||||
"Non filtrare",
|
||||
"Italiano",
|
||||
"ITA",
|
||||
"vosi"
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "perfil",
|
||||
"type": "list",
|
||||
"label": "profilo dei colori",
|
||||
"default": 0,
|
||||
"enabled": true,
|
||||
"visible": true,
|
||||
"lvalues": [
|
||||
"Sin color",
|
||||
"Perfil 5",
|
||||
"Perfil 4",
|
||||
"Perfil 3",
|
||||
"Perfil 2",
|
||||
"Perfil 1"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -1,57 +1,71 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# ------------------------------------------------------------
|
||||
# Canale per Eurostreaming
|
||||
# adattamento di Cineblog01
|
||||
# by Greko
|
||||
# ------------------------------------------------------------
|
||||
"""
|
||||
Riscritto per poter usufruire del modulo support.
|
||||
Problemi noti:
|
||||
Alcun regex possono migliorare
|
||||
Le regex non prendono tutto...
|
||||
server versystream : 'http://vcrypt.net/very/' # VeryS non decodifica il link :http://vcrypt.net/fastshield/
|
||||
server nowvideo.club da implementare nella cartella servers, altri server nei meandri del sito?!
|
||||
alcuni server tra cui nowvideo.club non sono implementati nella cartella servers
|
||||
Alcune sezioni di anime-cartoni non vanno, alcune hanno solo la lista degli episodi, ma non hanno link
|
||||
altre cambiano la struttura
|
||||
La sezione novità non fa apparire il titolo degli episodi
|
||||
|
||||
In episodios è stata aggiunta la possibilità di configurare la videoteca
|
||||
|
||||
"""
|
||||
|
||||
import re
|
||||
|
||||
from core import scrapertoolsV2, httptools, tmdb, support
|
||||
import channelselector
|
||||
from specials import autoplay, filtertools
|
||||
from core import scrapertoolsV2, httptools, servertools, tmdb, support
|
||||
from core.item import Item
|
||||
from platformcode import logger, config
|
||||
from specials import autoplay
|
||||
|
||||
__channel__ = "eurostreaming"
|
||||
host = config.get_channel_url(__channel__)
|
||||
headers = ['Referer', host]
|
||||
|
||||
IDIOMAS = {'Italiano': 'IT'}
|
||||
list_language = IDIOMAS.values()
|
||||
list_servers = ['verystream', 'wstream', 'speedvideo', 'flashx', 'nowvideo', 'streamango', 'deltabit', 'openload']
|
||||
list_quality = ['default']
|
||||
|
||||
checklinks = config.get_setting('checklinks', 'eurostreaming')
|
||||
checklinks_number = config.get_setting('checklinks_number', 'eurostreaming')
|
||||
__comprueba_enlaces__ = config.get_setting('comprueba_enlaces', 'eurostreaming')
|
||||
__comprueba_enlaces_num__ = config.get_setting('comprueba_enlaces_num', 'eurostreaming')
|
||||
|
||||
IDIOMAS = {'Italiano': 'ITA', 'Sub-ITA':'vosi'}
|
||||
list_language = IDIOMAS.values()
|
||||
|
||||
def mainlist(item):
|
||||
#import web_pdb; web_pdb.set_trace()
|
||||
support.log()
|
||||
itemlist = []
|
||||
|
||||
support.menu(itemlist, 'Serie TV', 'serietv', host, 'tvshow') # mettere sempre episode per serietv, anime!!
|
||||
support.menu(itemlist, 'Serie TV Archivio submenu', 'serietv', host + "category/serie-tv-archive/", 'tvshow')
|
||||
support.menu(itemlist, 'Ultimi Aggiornamenti submenu', 'serietv', host + 'aggiornamento-episodi/', 'tvshow', args='True')
|
||||
support.menu(itemlist, 'Anime / Cartoni', 'serietv', host + 'category/anime-cartoni-animati/', 'tvshow')
|
||||
support.menu(itemlist, 'Cerca...', 'search', host, 'tvshow')
|
||||
support.menu(itemlist, 'Serie TV', 'serietv', host, contentType = 'episode') # mettere sempre episode per serietv, anime!!
|
||||
support.menu(itemlist, 'Serie TV Archivio submenu', 'serietv', host + "category/serie-tv-archive/", contentType = 'episode')
|
||||
support.menu(itemlist, 'Ultimi Aggiornamenti submenu', 'serietv', host + 'aggiornamento-episodi/', args='True', contentType = 'episode')
|
||||
support.menu(itemlist, 'Anime / Cartoni', 'serietv', host + 'category/anime-cartoni-animati/', contentType = 'episode')
|
||||
support.menu(itemlist, 'Cerca...', 'search', host, contentType = 'episode')
|
||||
|
||||
## itemlist = filtertools.show_option(itemlist, item.channel, list_language, list_quality)
|
||||
# richiesto per autoplay
|
||||
autoplay.init(item.channel, list_servers, list_quality)
|
||||
autoplay.show_option(item.channel, itemlist)
|
||||
|
||||
itemlist.append(
|
||||
Item(channel='setting',
|
||||
action="channel_config",
|
||||
title=support.typo("Configurazione Canale color lime"),
|
||||
config=item.channel,
|
||||
folder=False,
|
||||
thumbnail=channelselector.get_thumb('setting_0.png'))
|
||||
)
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def serietv(item):
|
||||
def serietv(item):
|
||||
#import web_pdb; web_pdb.set_trace()
|
||||
# lista serie tv
|
||||
support.log()
|
||||
itemlist = []
|
||||
if item.args:
|
||||
@@ -65,69 +79,76 @@ def serietv(item):
|
||||
patronNext='a class="next page-numbers" href="?([^>"]+)">Avanti »</a>'
|
||||
|
||||
itemlist = support.scrape(item, patron_block='', patron=patron, listGroups=listGroups,
|
||||
patronNext=patronNext,
|
||||
action='episodios')
|
||||
patronNext=patronNext, action='episodios')
|
||||
return itemlist
|
||||
|
||||
|
||||
def episodios(item):
|
||||
support.log()
|
||||
## import web_pdb; web_pdb.set_trace()
|
||||
support.log("episodios")
|
||||
itemlist = []
|
||||
|
||||
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url).data
|
||||
#========
|
||||
if 'clicca qui per aprire' in data.lower():
|
||||
item.url = scrapertoolsV2.find_single_match(data, '"go_to":"(.*?)"')
|
||||
item.url = scrapertoolsV2.find_single_match(data, '"go_to":"([^"]+)"')
|
||||
item.url = item.url.replace("\\","")
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url).data
|
||||
elif 'clicca qui</span>' in data.lower():
|
||||
item.url = scrapertoolsV2.find_single_match(data, '<h2 style="text-align: center;"><a href="(.*?)">')
|
||||
item.url = scrapertoolsV2.find_single_match(data, '<h2 style="text-align: center;"><a href="([^"]+)">')
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url).data
|
||||
#=========
|
||||
patron = r'(?:<\/span>\w+ STAGIONE\s\d+ (?:\()?(ITA|SUB ITA)(?:\))?<\/div>'\
|
||||
'<div class="su-spoiler-content su-clearfix" style="display:none">|'\
|
||||
'(?:\s|\Wn)?(?:<strong>)?(\d&#.*?)(?:|–)?<a\s(.*?)<\/a><br\s\/>)'
|
||||
## '(?:<\/span>\w+ STAGIONE\s\d+ (?:\()?(ITA|SUB ITA)(?:\))?'\
|
||||
## '<\/div><div class="su-spoiler-content su-clearfix" style="display:none">|'\
|
||||
## '(?:\s|\Wn)?(?:<strong>)?(\d[&#].*?)(?:–|\W)?<a\s(.*?)<\/a><br\s\/>)'
|
||||
## '(?:<\/span>\w+ STAGIONE\s\d+ (?:\()?(ITA|SUB ITA)(?:\))?<\/div>'\
|
||||
## '<div class="su-spoiler-content su-clearfix" style="display:none">|'\
|
||||
## '\s(?:<strong>)?(\d[&#].*?)–<a\s(.*?)<\/a><br\s\/>)'
|
||||
listGroups = ['lang', 'title', 'url']
|
||||
itemlist = support.scrape(item, data=data, patron=patron,
|
||||
listGroups=listGroups, action='findvideos')
|
||||
|
||||
matches = scrapertoolsV2.find_multiple_matches(data,
|
||||
r'<span class="su-spoiler-icon"><\/span>(.*?)</div></div>')
|
||||
for match in matches:
|
||||
blocks = scrapertoolsV2.find_multiple_matches(match, r'(?:(\d×[a-zA-Z0-9].*?))<br \/>')
|
||||
season_lang = scrapertoolsV2.find_single_match(match, r'<\/span>.*?STAGIONE\s+\d+\s\(([^<>]+)\)').strip()
|
||||
|
||||
logger.info("blocks log: %s" % ( blocks ))
|
||||
for block in blocks:
|
||||
season_n, episode_n = scrapertoolsV2.find_single_match(block, r'(\d+)(?:×|×)(\d+)')
|
||||
titolo = scrapertoolsV2.find_single_match(block, r'[&#;]\d+[ ]([a-zA-Z0-9;&#.\s]+)[ ]?[^<>]')
|
||||
logger.info("block log: %s" % ( block ))
|
||||
|
||||
titolo = re.sub(r'×|×', "x", titolo).replace("’","'")
|
||||
item.infoLabels['season'] = season_n # permette di vedere il plot della stagione e...
|
||||
item.infoLabels['episode'] = episode_n # permette di vedere il plot della puntata e...
|
||||
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
action="findvideos",
|
||||
contentType='episode',
|
||||
title="[B]" + season_n + "x" + episode_n + " " + titolo + "[/B] " + season_lang,
|
||||
fulltitle=item.title, # Titolo nel video
|
||||
show=titolo + ":" + season_n + "x" + episode_n, # sottotitoletto nel video
|
||||
url=block,
|
||||
extra=item.extra,
|
||||
thumbnail=item.thumbnail,
|
||||
infoLabels=item.infoLabels
|
||||
))
|
||||
|
||||
tmdb.set_infoLabels_itemlist(itemlist, seekTmdb=True)
|
||||
|
||||
support.videolibrary(itemlist, item)
|
||||
# Permette la configurazione della videoteca senza andare nel menu apposito
|
||||
# così si possono Attivare/Disattivare le impostazioni direttamente dalla
|
||||
# pagina delle puntate
|
||||
itemlist.append(
|
||||
Item(channel='setting',
|
||||
action="channel_config",
|
||||
title=support.typo("Configurazione Videoteca color lime"),
|
||||
plot = 'Filtra per lingua utilizzando la configurazione della videoteca.\
|
||||
Escludi i video in sub attivando "Escludi streams... " e aggiungendo sub in Parole',
|
||||
config='videolibrary', #item.channel,
|
||||
folder=False,
|
||||
thumbnail=channelselector.get_thumb('setting_0.png')
|
||||
))
|
||||
|
||||
itemlist = filtertools.get_links(itemlist, item, list_language)
|
||||
return itemlist
|
||||
|
||||
# =========== def findvideos =============
|
||||
|
||||
def findvideos(item):
|
||||
support.log()
|
||||
itemlist =[]
|
||||
|
||||
# Requerido para FilterTools
|
||||
## itemlist = filtertools.get_links(itemlist, item, list_language)
|
||||
|
||||
itemlist = support.server(item, item.url)
|
||||
## support.videolibrary(itemlist, item)
|
||||
|
||||
return itemlist
|
||||
|
||||
# =========== def ricerca =============
|
||||
def search(item, texto):
|
||||
support.log()
|
||||
item.url = "%s?s=%s" % (host, texto)
|
||||
|
||||
try:
|
||||
return serietv(item)
|
||||
# Continua la ricerca in caso di errore
|
||||
@@ -142,8 +163,9 @@ def newest(categoria):
|
||||
support.log()
|
||||
itemlist = []
|
||||
item = Item()
|
||||
try:
|
||||
item.args= 'True'
|
||||
item.contentType= 'episode'
|
||||
item.args= 'True'
|
||||
try:
|
||||
item.url = "%saggiornamento-episodi/" % host
|
||||
item.action = "serietv"
|
||||
itemlist = serietv(item)
|
||||
@@ -160,10 +182,5 @@ def newest(categoria):
|
||||
|
||||
return itemlist
|
||||
|
||||
def findvideos(item):
|
||||
support.log()
|
||||
itemlist =[]
|
||||
|
||||
itemlist = support.server(item, item.url)
|
||||
|
||||
return itemlist
|
||||
def paginator(item):
|
||||
pass
|
||||
|
||||
@@ -321,7 +321,7 @@ def thumb(itemlist=[]):
|
||||
icon_dict = {'channels_movie':['film'],
|
||||
'channels_tvshow':['serie','tv','episodi','episodio'],
|
||||
'channels_documentary':['documentari','documentario'],
|
||||
'news':['novità', "novita'"],
|
||||
'news':['novità', "novita'", 'aggiornamenti'],
|
||||
'now_playing':['cinema', 'in sala'],
|
||||
'channels_anime':['anime'],
|
||||
'genres':['genere', 'generi', 'categorie', 'categoria'],
|
||||
@@ -338,13 +338,13 @@ def thumb(itemlist=[]):
|
||||
'channels_grotesque':['grottesco'],
|
||||
'channels_war':['guerra'],
|
||||
'horror':['horror'],
|
||||
'lucky': ['fortunato'], # se potete inserire la icona anche per questa voce
|
||||
'lucky': ['fortunato'],
|
||||
'channels_musical':['musical'],
|
||||
'channels_mistery':['mistero', 'giallo'],
|
||||
'channels_noir':['noir'],
|
||||
'popular' : ['popolari','popolare', 'più visti'],
|
||||
'channels_thriller':['thriller'],
|
||||
'top_rated' : ['fortunato'], #da tocgliere aggiunte la voce lucky o quello che volete
|
||||
'top_rated' : ['fortunato'],
|
||||
'channels_western':['western'],
|
||||
'channels_vos':['sub','sub-ita'],
|
||||
'channels_romance':['romantico','sentimentale'],
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# -----------------------------------------------------------
|
||||
# support functions that are needed by many channels, to no repeat the same code
|
||||
import base64
|
||||
import inspect
|
||||
@@ -112,8 +114,12 @@ def scrape(item, patron = '', listGroups = [], headers="", blacklist="", data=""
|
||||
# patron = 'blablabla'
|
||||
# headers = [['Referer', host]]
|
||||
# blacklist = 'Request a TV serie!'
|
||||
# return support.scrape(item, itemlist, patron, ['thumb', 'quality', 'url', 'title', 'year', 'plot', 'episode', 'lang'],
|
||||
# return support.scrape(item, itemlist, patron, ['thumb', 'quality', 'url', 'title', 'title2', 'year', 'plot', 'episode', 'lang'],
|
||||
# headers=headers, blacklist=blacklist)
|
||||
# listGroups
|
||||
# thumb = immagine, quality = qualità, url = link singolo o gruppo, title = titolo film o serie, title2 = titolo aggiuntivo
|
||||
# year = anno del film o della serie, plot = descrizione film o serie, episode = numero stagione - numero episodio in caso di serie,
|
||||
# lang = lingua del video
|
||||
# 'type' is a check for typologies of content e.g. Film or TV Series
|
||||
# 'episode' is a key to grab episode numbers if it is separated from the title
|
||||
# IMPORTANT 'type' is a special key, to work need type_content_dict={} and type_action_dict={}
|
||||
@@ -145,6 +151,7 @@ def scrape(item, patron = '', listGroups = [], headers="", blacklist="", data=""
|
||||
log('MATCHES =', matches)
|
||||
|
||||
known_keys = ['url', 'title', 'title2', 'episode', 'thumb', 'quality', 'year', 'plot', 'duration', 'genere', 'rating', 'type', 'lang'] #by greko aggiunto episode
|
||||
lang = '' # aggiunto per gestire i siti con pagine di serietv dove si hanno i video in ita e in subita
|
||||
|
||||
for match in matches:
|
||||
if len(listGroups) > len(match): # to fix a bug
|
||||
@@ -158,7 +165,7 @@ def scrape(item, patron = '', listGroups = [], headers="", blacklist="", data=""
|
||||
val = scrapertoolsV2.find_single_match(item.url, 'https?://[a-z0-9.-]+') + val
|
||||
scraped[kk] = val
|
||||
|
||||
title = scrapertoolsV2.decodeHtmlentities(scraped["title"]).replace('"', "'").strip() # fix by greko da " a '
|
||||
title = scrapertoolsV2.htmlclean(scrapertoolsV2.decodeHtmlentities(scraped["title"])).replace('’', '\'').replace('"', "'").strip() # fix by greko da " a '
|
||||
plot = scrapertoolsV2.htmlclean(scrapertoolsV2.decodeHtmlentities(scraped["plot"]))
|
||||
|
||||
longtitle = typo(title, 'bold')
|
||||
@@ -167,13 +174,17 @@ def scrape(item, patron = '', listGroups = [], headers="", blacklist="", data=""
|
||||
scraped['episode'] = re.sub(r'\s-\s|-|x|–', 'x' , scraped['episode'])
|
||||
longtitle = typo(scraped['episode'] + ' - ', 'bold') + longtitle
|
||||
if scraped['title2']:
|
||||
title2 = scrapertoolsV2.decodeHtmlentities(scraped["title2"]).replace('"', "'").strip()
|
||||
title2 = scrapertoolsV2.htmlclean(scrapertoolsV2.decodeHtmlentities(scraped["title2"])).replace('"', "'").strip()
|
||||
longtitle = longtitle + typo(title2, 'bold _ -- _')
|
||||
if scraped["lang"]:
|
||||
if 'sub' in scraped["lang"].lower():
|
||||
|
||||
## Aggiunto/modificato per gestire i siti che hanno i video
|
||||
## in ita e subita delle serie tv nella stessa pagina
|
||||
if scraped['lang']:
|
||||
if 'sub' in scraped['lang'].lower():
|
||||
lang = 'Sub-ITA'
|
||||
else:
|
||||
lang = 'ITA'
|
||||
lang = 'ITA'
|
||||
if lang != '':
|
||||
longtitle += typo(lang, '_ [] color kod')
|
||||
|
||||
if item.infoLabels["title"] or item.fulltitle: # if title is set, probably this is a list of episodes or video sources
|
||||
@@ -216,6 +227,7 @@ def scrape(item, patron = '', listGroups = [], headers="", blacklist="", data=""
|
||||
title=longtitle,
|
||||
fulltitle=title,
|
||||
show=title,
|
||||
language = lang if lang != '' else '',
|
||||
quality=scraped["quality"],
|
||||
url=scraped["url"],
|
||||
infoLabels=infolabels,
|
||||
|
||||
@@ -53,6 +53,8 @@ def get_video_url(page_url, premium=False, user="", password="", video_password=
|
||||
from lib import unshortenit
|
||||
data, status = unshortenit.unshorten(url)
|
||||
logger.info("Data - Status zcrypt linkup : [%s] [%s] " %(data, status))
|
||||
if '/speedx/' in data: # aggiunto per server speedvideo
|
||||
data = data.replace('http://linkup.pro/speedx', 'http://speedvideo.net')
|
||||
# fix by greko fine
|
||||
else:
|
||||
data = ""
|
||||
|
||||
@@ -1,70 +1,44 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
import time
|
||||
import urllib
|
||||
|
||||
from core import httptools
|
||||
from core import scrapertools
|
||||
from platformcode import logger
|
||||
|
||||
from servers import turbovid
|
||||
|
||||
def test_video_exists(page_url):
|
||||
logger.info("(page_url='%s')" % page_url)
|
||||
data = httptools.downloadpage(page_url).data
|
||||
if "Not Found" in data or "File Does not Exist" in data:
|
||||
return False, "[deltabit] El fichero no existe o ha sido borrado"
|
||||
return True, ""
|
||||
|
||||
return turbovid.test_video_exists(page_url)
|
||||
|
||||
def get_video_url(page_url, premium=False, user="", password="", video_password=""):
|
||||
logger.info("(deltabit page_url='%s')" % page_url)
|
||||
video_urls = []
|
||||
data = httptools.downloadpage(page_url).data
|
||||
data = data.replace('"', "'")
|
||||
page_url_post = scrapertools.find_single_match(data, "<Form method='POST' action='([^']+)'>")
|
||||
imhuman = "&imhuman=" + scrapertools.find_single_match(data, "name='imhuman' value='([^']+)'").replace(" ", "+")
|
||||
post = urllib.urlencode({k: v for k, v in scrapertools.find_multiple_matches(data, "name='([^']+)' value='([^']*)'")}) + imhuman
|
||||
time.sleep(6)
|
||||
data = httptools.downloadpage(page_url_post, post=post).data
|
||||
## logger.info("(data page_url='%s')" % data)
|
||||
sources = scrapertools.find_single_match(data, 'sources: \[([^\]]+)\]')
|
||||
|
||||
for media_url in scrapertools.find_multiple_matches(sources, '"([^"]+)"'):
|
||||
media_url = media_url.replace('https:', 'http:')
|
||||
ext = scrapertools.get_filename_from_url(media_url)[-4:]
|
||||
video_urls.append(["%s [deltabit]" % (ext), media_url])
|
||||
return video_urls
|
||||
return turbovid.get_video_url(page_url, premium, user, password, video_password, 'deltabit')
|
||||
|
||||
## logger.info("deltabit url=" + page_url)
|
||||
##import time
|
||||
##import urllib
|
||||
##
|
||||
##from core import httptools
|
||||
##from core import scrapertools
|
||||
##from platformcode import logger
|
||||
##
|
||||
##
|
||||
##def test_video_exists(page_url):
|
||||
## logger.info("(page_url='%s')" % page_url)
|
||||
## data = httptools.downloadpage(page_url).data
|
||||
## code = scrapertools.find_multiple_matches(data, '<input type="hidden" name="[^"]+" value="([^"]+)"')
|
||||
## time.sleep(6)
|
||||
## data = httptools.downloadpage(page_url+'?op='+code[0]+\
|
||||
## '&id='+code[1]+'&fname='+code[2]+'&hash='+code[3]).data
|
||||
##
|
||||
## logger.info("DATA deltabit : %s" % data)
|
||||
|
||||
|
||||
|
||||
## https://deltabit.co/6zragsekoole?op=download1&usr_login=%27%27&id=6zragsekoole&fname=New.Amsterdam.2018.Episodio.1.Come.Posso.Aiutare.iTALiAN.WEBRip.x264-GeD.mkv&referer=%27%27&hash=24361-79-32-1557854113-cc51baafbf1530f43b746133fbd293ee
|
||||
## https://deltabit.co/6zragsekoole?op=download1&usr_login=''&id=6zragsekoole&fname=New.Amsterdam.2018.Episodio.1.Come.Posso.Aiutare.iTALiAN.WEBRip.x264-GeD.mkv&referer=''&hash=24361-79-32-1557854113-cc51baafbf1530f43b746133fbd293ee
|
||||
|
||||
## video_urls = page_url+'?op='+code[0]+'&usr_login='+code[1]+'&id='+code[2]+'&fname='+code[3]+'&referer='+code[4]+'&hash='+code[5]
|
||||
|
||||
## logger.info("Delta bit [%s]: " % page_url)
|
||||
|
||||
## code = scrapertools.find_single_match(data, 'name="code" value="([^"]+)')
|
||||
## hash = scrapertools.find_single_match(data, 'name="hash" value="([^"]+)')
|
||||
## post = "op=download1&code=%s&hash=%s&imhuman=Proceed+to+video" %(code, hash)
|
||||
## data1 = httptools.downloadpage("http://m.vidtome.stream/playvideo/%s" %code, post=post).data
|
||||
## if "Not Found" in data or "File Does not Exist" in data:
|
||||
## return False, "[deltabit] El fichero no existe o ha sido borrado"
|
||||
## return True, ""
|
||||
##
|
||||
##
|
||||
##def get_video_url(page_url, premium=False, user="", password="", video_password=""):
|
||||
#### logger.info("(deltabit page_url='%s')" % page_url)
|
||||
## video_urls = []
|
||||
## media_urls = scrapertools.find_multiple_matches(data1, 'file: "([^"]+)')
|
||||
## for media_url in media_urls:
|
||||
## data = httptools.downloadpage(page_url).data
|
||||
## data = data.replace('"', "'")
|
||||
## page_url_post = scrapertools.find_single_match(data, "<Form method='POST' action='([^']+)'>")
|
||||
## imhuman = "&imhuman=" + scrapertools.find_single_match(data, "name='imhuman' value='([^']+)'").replace(" ", "+")
|
||||
## post = urllib.urlencode({k: v for k, v in scrapertools.find_multiple_matches(data, "name='([^']+)' value='([^']*)'")}) + imhuman
|
||||
## time.sleep(6)
|
||||
## data = httptools.downloadpage(page_url_post, post=post).data
|
||||
#### logger.info("(data page_url='%s')" % data)
|
||||
## sources = scrapertools.find_single_match(data, 'sources: \[([^\]]+)\]')
|
||||
##
|
||||
## for media_url in scrapertools.find_multiple_matches(sources, '"([^"]+)"'):
|
||||
## media_url = media_url.replace('https:', 'http:')
|
||||
## ext = scrapertools.get_filename_from_url(media_url)[-4:]
|
||||
## video_urls.append(["%s [vidtomestream]" % (ext), media_url])
|
||||
## video_urls.reverse()
|
||||
## for video_url in video_urls:
|
||||
## logger.info("%s" % (video_url[0]))
|
||||
## video_urls.append(["%s [deltabit]" % (ext), media_url])
|
||||
## return video_urls
|
||||
|
||||
|
||||
|
||||
75
servers/nowvideo.json
Normal file
75
servers/nowvideo.json
Normal file
@@ -0,0 +1,75 @@
|
||||
{
|
||||
"id": "nowvideo",
|
||||
"name": "nowvideo",
|
||||
"active": true,
|
||||
"thumbnail": "http://nowvideo.club/images/logo.png",
|
||||
"find_videos": {
|
||||
"ignore_urls": [],
|
||||
"patterns": [
|
||||
{
|
||||
"pattern": "nowvideo.club/(?:play|videos/)([A-z0-9]+)",
|
||||
"url": "http:\/\/nowvideo.club\/play\/\\1"
|
||||
},
|
||||
{
|
||||
"pattern": "nowvideo.club/(?:videos|play/)([A-z0-9]+)",
|
||||
"url": "http:\/\/nowvideo.club\/videos/\\1"
|
||||
}
|
||||
]
|
||||
},
|
||||
"free": true,
|
||||
"premium": [
|
||||
"nowvideo",
|
||||
"realdebrid"
|
||||
],
|
||||
"settings": [
|
||||
{
|
||||
"default": false,
|
||||
"enabled": true,
|
||||
"id": "black_list",
|
||||
"label": "@60654",
|
||||
"type": "bool",
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"default": 0,
|
||||
"enabled": true,
|
||||
"id": "favorites_servers_list",
|
||||
"label": "@60655",
|
||||
"lvalues": [
|
||||
"No",
|
||||
"1",
|
||||
"2",
|
||||
"3",
|
||||
"4",
|
||||
"5"
|
||||
],
|
||||
"type": "list",
|
||||
"visible": false
|
||||
},
|
||||
{
|
||||
"default": false,
|
||||
"enabled": true,
|
||||
"id": "premium",
|
||||
"label": "@70272",
|
||||
"type": "bool",
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"default": "",
|
||||
"enabled": "eq(-1,true)",
|
||||
"id": "user",
|
||||
"label": "@30014",
|
||||
"type": "text",
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"default": "",
|
||||
"enabled": "eq(-2,true)+!eq(-1,'')",
|
||||
"hidden": true,
|
||||
"id": "password",
|
||||
"label": "@30015",
|
||||
"type": "text",
|
||||
"visible": true
|
||||
}
|
||||
]
|
||||
}
|
||||
74
servers/nowvideo.py
Normal file
74
servers/nowvideo.py
Normal file
@@ -0,0 +1,74 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
import urllib
|
||||
import urlparse
|
||||
from core import httptools
|
||||
from core import scrapertools
|
||||
from platformcode import logger#, config
|
||||
|
||||
headers = [['User-Agent', 'Mozilla/5.0 (Windows NT 6.1; WOW64; rv:54.0) Gecko/20100101 Firefox/54.0']]
|
||||
|
||||
def test_video_exists(page_url):
|
||||
logger.info("(page_url='%s')" % page_url)
|
||||
data = httptools.downloadpage(page_url).data
|
||||
if "Not Found" in data or "File was deleted" in data or "The file is being converted" in data or "Please try again later" in data:
|
||||
return False, config.get_localized_string(70293) % "NowVideo"
|
||||
elif "no longer exists" in data:
|
||||
return False, config.get_localized_string(70292) % "NowVideo"
|
||||
return True, ""
|
||||
|
||||
|
||||
def get_video_url(page_url, premium=False, user="", password="", video_password=""):
|
||||
host = 'http://nowvideo.club'
|
||||
logger.info("(nowvideo page_url='%s')" % page_url)
|
||||
video_urls = []
|
||||
data = httptools.downloadpage(page_url).data
|
||||
page_url_post = scrapertools.find_single_match(data, '<Form id="[^"]+" method="POST" action="([^"]+)">')
|
||||
page_url_post = page_url_post.replace('..', '')
|
||||
imhuman = '&imhuman=' + scrapertools.find_single_match(data, 'name="imhuman" value="([^"]+)"').replace(" ", "+")
|
||||
post = urllib.urlencode({k: v for k, v in scrapertools.find_multiple_matches(data, 'name="([^"]+)" value="([^"]*)"')}) + imhuman
|
||||
data = httptools.downloadpage(host + page_url_post, post=post).data
|
||||
logger.info("nowvideo data page_url2 ='%s'" % data)
|
||||
|
||||
headers.append(['Referer', page_url])
|
||||
post_data = scrapertools.find_single_match(data,"</div>\s*<script>(eval.function.p,a,c,k,e,.*?)\s*</script>")
|
||||
if post_data != "":
|
||||
from lib import jsunpack
|
||||
data = jsunpack.unpack(post_data)
|
||||
|
||||
block = scrapertools.find_single_match(data, 'sources:\s*\[[^\]]+\]')
|
||||
if block: data = block
|
||||
|
||||
media_urls = scrapertools.find_multiple_matches(data, '(http.*?\.mp4)')
|
||||
_headers = urllib.urlencode(dict(headers))
|
||||
|
||||
for media_url in media_urls:
|
||||
#logger.info("nowvideo data page_url2 ='%s'" % media_url)
|
||||
video_urls.append([" mp4 [nowvideo] ", media_url + '|' + _headers])
|
||||
|
||||
for video_url in media_urls:
|
||||
logger.info("[nowvideo.py] %s - %s" % (video_url[0], video_url[1]))
|
||||
|
||||
return video_urls
|
||||
|
||||
|
||||
def find_videos(data):
|
||||
encontrados = set()
|
||||
devuelve = []
|
||||
|
||||
patronvideos = r"nowvideo.club/(?:play|videos)?([a-z0-9A-Z]+)"
|
||||
logger.info("[nowvideo.py] find_videos #" + patronvideos + "#")
|
||||
matches = re.compile(patronvideos, re.DOTALL).findall(data)
|
||||
|
||||
for match in matches:
|
||||
titulo = "[nowvideo]"
|
||||
url = 'http://nowvideo.club/%s' % match
|
||||
|
||||
if url not in encontrados:
|
||||
logger.info(" url=" + url)
|
||||
devuelve.append([titulo, url, 'nowvideo'])
|
||||
encontrados.add(url)
|
||||
else:
|
||||
logger.info(" url duplicada=" + url)
|
||||
|
||||
return devuelve
|
||||
@@ -42,4 +42,4 @@
|
||||
"visible": false
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
##
|
||||
|
||||
from core import httptools, scrapertools
|
||||
from platformcode import config, logger
|
||||
|
||||
|
||||
def test_video_exists(page_url):
|
||||
logger.info("(page_url='%s')" % page_url)
|
||||
|
||||
@@ -14,23 +14,25 @@ def test_video_exists(page_url):
|
||||
|
||||
return True, ""
|
||||
|
||||
|
||||
def get_video_url(page_url,
|
||||
premium=False,
|
||||
user="",
|
||||
password="",
|
||||
video_password=""):
|
||||
def get_video_url(page_url, premium=False, user="", password="", video_password=""):
|
||||
logger.info("url=" + page_url)
|
||||
video_urls = []
|
||||
|
||||
|
||||
data = httptools.downloadpage(page_url).data
|
||||
|
||||
media_urls = scrapertools.find_multiple_matches(data, r"file:[^']'([^']+)',\s*label:[^\"]\"([^\"]+)\"")
|
||||
|
||||
logger.info("speed video - media urls: %s " % media_urls)
|
||||
for media_url, label in media_urls:
|
||||
media_url = httptools.downloadpage(media_url, only_headers=True, follow_redirects=False).headers.get("location", "")
|
||||
|
||||
if media_url:
|
||||
video_urls.append([label + " " + media_url.rsplit('.', 1)[1] + ' [speedvideo]', media_url])
|
||||
|
||||
logger.info("speed video - media urls: %s " % video_urls)
|
||||
return video_urls
|
||||
|
||||
|
||||
##,
|
||||
## {
|
||||
## "pattern": "speedvideo.net/([A-Z0-9a-z]+)",
|
||||
## "url": "https:\/\/speedvideo.net\/\\1"
|
||||
## }
|
||||
|
||||
42
servers/turbovid.json
Normal file
42
servers/turbovid.json
Normal file
@@ -0,0 +1,42 @@
|
||||
{
|
||||
"active": true,
|
||||
"find_videos": {
|
||||
"ignore_urls": [],
|
||||
"patterns": [
|
||||
{
|
||||
"pattern": "turbovid.me/([A-z0-9]+)",
|
||||
"url": "http://turbovid.me/\\1"
|
||||
}
|
||||
]
|
||||
},
|
||||
"free": true,
|
||||
"id": "turbovid",
|
||||
"name": "turbovid",
|
||||
"settings": [
|
||||
{
|
||||
"default": false,
|
||||
"enabled": true,
|
||||
"id": "black_list",
|
||||
"label": "@60654",
|
||||
"type": "bool",
|
||||
"visible": true
|
||||
},
|
||||
{
|
||||
"default": 0,
|
||||
"enabled": true,
|
||||
"id": "favorites_servers_list",
|
||||
"label": "@60655",
|
||||
"lvalues": [
|
||||
"No",
|
||||
"1",
|
||||
"2",
|
||||
"3",
|
||||
"4",
|
||||
"5"
|
||||
],
|
||||
"type": "list",
|
||||
"visible": false
|
||||
}
|
||||
],
|
||||
"thumbnail": "http://turbovid.me/img/logo.png"
|
||||
}
|
||||
37
servers/turbovid.py
Normal file
37
servers/turbovid.py
Normal file
@@ -0,0 +1,37 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
import urllib
|
||||
import time
|
||||
from core import httptools
|
||||
from core import scrapertools
|
||||
from platformcode import logger
|
||||
|
||||
|
||||
def test_video_exists(page_url):
|
||||
logger.info("(page_url='%s')" % page_url)
|
||||
data = httptools.downloadpage(page_url).data
|
||||
if "Not Found" in data or "File Does not Exist" in data:
|
||||
return False, "[turbovid.me] El fichero no existe o ha sido borrado"
|
||||
return True, ""
|
||||
|
||||
|
||||
def get_video_url(page_url, premium=False, user="", password="", video_password="", server='turbovid'):
|
||||
|
||||
logger.info("(turbovid page_url='%s')" % page_url)
|
||||
video_urls = []
|
||||
data = httptools.downloadpage(page_url).data
|
||||
data = data.replace('"', "'")
|
||||
page_url_post = scrapertools.find_single_match(data, "<Form method='POST' action='([^']+)'>")
|
||||
imhuman = "&imhuman=" + scrapertools.find_single_match(data, "name='imhuman' value='([^']+)'").replace(" ", "+")
|
||||
post = urllib.urlencode({k: v for k, v in scrapertools.find_multiple_matches(data, "name='([^']+)' value='([^']*)'")}) + imhuman
|
||||
|
||||
time.sleep(6)
|
||||
data = httptools.downloadpage(page_url_post, post=post).data
|
||||
logger.info("(data page_url='%s')" % data)
|
||||
sources = scrapertools.find_single_match(data, 'sources: \[([^\]]+)\]')
|
||||
|
||||
for media_url in scrapertools.find_multiple_matches(sources, '"([^"]+)"'):
|
||||
media_url = media_url.replace('https:', 'http:')
|
||||
ext = scrapertools.get_filename_from_url(media_url)[-4:]
|
||||
video_urls.append(["%s [turbovid]" % (ext), media_url])
|
||||
return video_urls
|
||||
@@ -9,7 +9,11 @@
|
||||
{
|
||||
"pattern": "wstream.video/(?:embed-|videos/|video/)?([a-z0-9A-Z]+)",
|
||||
"url": "http:\/\/wstream.video\/\\1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"pattern": "wstream.video/(?:embed-|videos/|video/)?([a-z0-9A-Z]+)",
|
||||
"url": "http:\/\/wstream.video\/video\/\\1"
|
||||
}
|
||||
],
|
||||
"ignore_urls": [ ]
|
||||
},
|
||||
@@ -39,4 +43,4 @@
|
||||
"visible": false
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user