* fix next page

* testing new filmontv

* Wstream quick fix, no resolution displayed :(

* new filmontv

* now regex is ok

* fix .po files

* +netlovers

* working on filmontv

* fix debriders

* new updater

* updater

* fix crash

* fix updater and re-add dev mode

* new url eurostreaming

* Delete netlovers.py

* Delete netlovers.json

* -net from menù

* fix eurostreaming: numero stagione e newest (#50)

* fix canale

* fix newest

* fix numero puntata

* cleanup

* cleanup 2

* fix updater crash on windows

* Fix Animeworld

* Nuovo Autorenumber

* initial background downloader support

* ops

* Update channels.json

* Update channels.json

* fix openload

* move json update to cohesist with updater

* disable json url updates

* fix typo

* fix typo 2

* Add files via upload

* Add files via upload

* fix autoplay in community channels

* fix toonitalia

* Fix Toonitalia

* workaround serietvsubita

* Nuova Rinumerazione Automatica

* Fix per Rinumerazione Automatica

* workaround updater

* Fix on air

* ops

* Personalizzazione sezione "Oggi in TV"

* Aggiunto orario sezione Oggi in TV

* aggiunto bit.ly (#56)

* aggiunto bit.ly

* Aggiunta personalizzazione homepage

* Revert "initial background downloader support"

This reverts commit f676ab0f

* KoD 0.4
This commit is contained in:
mac12m99
2019-06-30 10:35:48 +02:00
committed by GitHub
parent 7551aed8ba
commit 3fb9b068d9
47 changed files with 1340 additions and 664 deletions
+16
View File
@@ -57,6 +57,22 @@
"enabled": true,
"visible": true,
"lvalues": ["Non filtrare", "IT"]
},
{
"id": "autorenumber",
"type": "bool",
"label": "@70712",
"default": false,
"enabled": true,
"visible": true
},
{
"id": "autorenumber_mode",
"type": "bool",
"label": "@70688",
"default": false,
"enabled": true,
"visible": "eq(-1,true)"
}
]
}
+1
View File
@@ -38,6 +38,7 @@ def mainlist(item):
autoplay.init(item.channel, list_servers, list_quality)
autoplay.show_option(item.channel, itemlist)
support.channel_config(item, itemlist)
return itemlist
+16
View File
@@ -65,6 +65,22 @@
"enabled": true,
"visible": true,
"lvalues": ["Non filtrare","IT"]
},
{
"id": "autorenumber",
"type": "bool",
"label": "@70712",
"default": false,
"enabled": true,
"visible": true
},
{
"id": "autorenumber_mode",
"type": "bool",
"label": "@70688",
"default": false,
"enabled": true,
"visible": "eq(-1,true)"
}
]
}
+17 -1
View File
@@ -65,6 +65,22 @@
"enabled": true,
"visible": true,
"lvalues": ["No filtrar","Italiano"]
}
},
{
"id": "autorenumber",
"type": "bool",
"label": "@70712",
"default": false,
"enabled": true,
"visible": true
},
{
"id": "autorenumber_mode",
"type": "bool",
"label": "@70688",
"default": false,
"enabled": true,
"visible": "eq(-1,true)"
}
]
}
+27 -26
View File
@@ -172,7 +172,7 @@ def video(item):
log()
itemlist = []
matches, data = support.match(item, r'<a href="([^"]+)" class[^>]+><img src="([^"]+)"(.*?)data-jtitle="([^"]+)" .*?>(.*?)<\/a>', headers=headers)
matches, data = support.match(item, r'<a href="([^"]+)" class[^>]+><img src="([^"]+)"(.*?)data-jtitle="([^"]+)" .*?>(.*?)<\/a>', '<div class="widget-body">(.*?)<div id="sidebar"', headers=headers)
for scrapedurl, scrapedthumb ,scrapedinfo, scrapedoriginal, scrapedtitle in matches:
# Cerca Info come anno o lingua nel Titolo
@@ -245,21 +245,21 @@ def video(item):
fulltitle=title,
show=title,
thumbnail=scrapedthumb,
context = autoplay.context))
context = autoplay.context,
number= '1'))
tmdb.set_infoLabels_itemlist(itemlist, seekTmdb=True)
autorenumber.renumber(itemlist)
# Next page
support.nextPage(itemlist, item, data, r'<a\sclass="page-link"\shref="([^"]+)"\srel="next"\saria-label="Successiva')
support.nextPage(itemlist, item, data, r'href="([^"]+)" rel="next"', resub=['&amp;','&'])
return itemlist
def episodios(item):
log()
itemlist = []
patron_block = r'<div class="widget servers".*?>(.*?)<div id="download"'
patron_block = r'server active(.*?)server hidden '
patron = r'<li><a [^=]+="[^"]+"[^=]+="[^"]+"[^=]+="[^"]+"[^=]+="[^"]+"[^=]+="[^"]+" href="([^"]+)"[^>]+>([^<]+)<'
matches = support.match(item, patron, patron_block)[0]
@@ -275,9 +275,10 @@ def episodios(item):
show=scrapedtitle,
plot=item.plot,
fanart=item.thumbnail,
thumbnail=item.thumbnail))
thumbnail=item.thumbnail,
number=scrapedtitle))
autorenumber.renumber(itemlist, item,'bold')
autorenumber.renumber(itemlist, item, 'bold')
support.videolibrary(itemlist, item)
return itemlist
@@ -285,31 +286,31 @@ def episodios(item):
def findvideos(item):
log()
itemlist = []
matches, data = support.match(item, r'class="tab.*?data-name="([0-9]+)">([^<]+)</span', headers=headers)
videoData = ''
for serverid, servername in matches:
block = scrapertoolsV2.find_multiple_matches(data,'data-id="'+serverid+'">(.*?)<div class="server')
id = scrapertoolsV2.find_single_match(str(block),r'<a data-id="([^"]+)" data-base="'+item.fulltitle+'"')
dataJson = httptools.downloadpage('%s/ajax/episode/info?id=%s&server=%s&ts=%s' % (host, id, serverid, int(time.time())), headers=[['x-requested-with', 'XMLHttpRequest']]).data
json = jsontools.load(dataJson)
log('JSON= ',json)
log('ITEM= ',item)
id = scrapertoolsV2.find_single_match(str(block),r'<a data-id="([^"]+)" data-base="'+item.number+'"')
if id:
dataJson = httptools.downloadpage('%s/ajax/episode/info?id=%s&server=%s&ts=%s' % (host, id, serverid, int(time.time())), headers=[['x-requested-with', 'XMLHttpRequest']]).data
json = jsontools.load(dataJson)
videoData +='\n'+json['grabber']
videoData +='\n'+json['grabber']
if serverid == '28':
itemlist.append(
Item(
channel=item.channel,
action="play",
title='diretto',
quality='',
url=json['grabber'],
server='directo',
show=item.show,
contentType=item.contentType,
folder=False))
if serverid == '28':
itemlist.append(
Item(
channel=item.channel,
action="play",
title='diretto',
quality='',
url=json['grabber'],
server='directo',
show=item.show,
contentType=item.contentType,
folder=False))
return support.server(item, videoData, itemlist)
+16
View File
@@ -31,6 +31,22 @@
"default": true,
"enabled": true,
"visible": true
},
{
"id": "autorenumber",
"type": "bool",
"label": "@70712",
"default": false,
"enabled": true,
"visible": true
},
{
"id": "autorenumber_mode",
"type": "bool",
"label": "@70688",
"default": false,
"enabled": true,
"visible": "eq(-1,true)"
}
]
}
+7 -5
View File
@@ -14,8 +14,8 @@ from platformcode import logger, config
__channel__ = "dreamsub"
host = config.get_channel_url(__channel__)
list_servers = ['animeworld', 'verystream', 'streamango', 'openload', 'directo']
list_quality = ['default', '480p', '720p', '1080p']
list_servers = ['verystream', 'streamango', 'openload']
list_quality = ['default']
def mainlist(item):
@@ -25,7 +25,7 @@ def mainlist(item):
menu(itemlist, 'Anime / Cartoni', 'peliculas', host + '/anime', 'tvshow')
menu(itemlist, 'Categorie', 'categorie', host + '/filter?genere=', 'tvshow')
menu(itemlist, 'Ultimi Episodi', 'last', host, 'episode')
menu(itemlist, 'Cerca', 'search')
menu(itemlist, 'Cerca...', 'search')
support.aplay(item, itemlist, list_servers, list_quality)
support.channel_config(item, itemlist)
@@ -69,7 +69,8 @@ def newest(categoria):
def peliculas(item):
itemlist = scrape(item, r'Lingua[^<]+<br>\s*<a href="(?:Lista episodi )?([^"]+)" title="(?:Lista episodi )?(.*?)(?: \(([0-9]+)\))?(?: Streaming)?">', ['url', 'title', 'year'], action='episodios', patron_block='<input type="submit" value="Vai!" class="blueButton">(.*?)<div class="footer">', patronNext='<li class="currentPage">[^>]+><li[^<]+<a href="([^"]+)">')
return renumber(itemlist)
renumber(itemlist)
return itemlist
def last(item):
@@ -94,7 +95,8 @@ def categorie(item):
def episodios(item):
itemlist = scrape(item, r'<li><a href="([^"]+)"[^<]+<b>(.*?)<\/b>[^>]+>([^<]+)<\/i>', ['url','title','title2'], patron_block='<div class="seasonEp">(.*?)<div class="footer">')
return renumber(itemlist, item, 'bold')
renumber(itemlist, item, 'bold')
return itemlist
def findvideos(item):
log()
+1 -1
View File
@@ -12,7 +12,7 @@
"id": "channel_host",
"type": "text",
"label": "Host del canale",
"default": "https://eurostreaming.cafe/",
"default": "https://eurostreaming.cafe",
"enabled": true,
"visible": true
},
+3 -3
View File
@@ -96,7 +96,7 @@ def episodios(item):
#=========
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\/>)'
'(?:\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\/>)'
@@ -141,7 +141,7 @@ def findvideos(item):
# =========== def ricerca =============
def search(item, texto):
support.log()
item.url = "%s?s=%s" % (host, texto)
item.url = "%s/?s=%s" % (host, texto)
try:
return serietv(item)
# Continua la ricerca in caso di errore
@@ -159,7 +159,7 @@ def newest(categoria):
item.contentType= 'episode'
item.args= 'True'
try:
item.url = "%saggiornamento-episodi/" % host
item.url = "%s/aggiornamento-episodi/" % host
item.action = "serietv"
itemlist = serietv(item)
+2 -2
View File
@@ -117,7 +117,7 @@ def categorias_film(item):
for scrapedurl, scrapedtitle in matches:
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="peliculas_categorias",
title="[COLOR azure]" + scrapedtitle + "[/COLOR]",
url=scrapedurl,
@@ -139,7 +139,7 @@ def categorias_serie(item):
for scrapedurl, scrapedtitle in matches:
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
contentType='tvshow',
action="peliculas_serie",
title="[COLOR azure]" + scrapedtitle + "[/COLOR]",
+9 -9
View File
@@ -57,7 +57,7 @@ def carousel(item, regex=r'<h2>Ultime Richieste Inserite</h2>(.*?)<header>', con
scrapedtitle = scrapertools.decodeHtmlentities(scrapedtitle)
scrapedtitle = re.sub(r'[0-9]{4}', "", scrapedtitle)
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="findvideos",
contentType=contentType,
title=scrapedtitle + " " + "[COLOR orange][" + year + "][/COLOR]",
@@ -113,7 +113,7 @@ def top_imdb(item, contentType='movie', regex=r'<h1.*?TOP IMDb.*?<h3>(.*?)<h3>')
scrapedtitle = re.sub(r'[0-9]{4}', "", scrapedtitle)
scrapedthumbnail = scrapedthumbnail.replace ("-90x135","").replace("/w92/", "/w600_and_h900_bestv2/")
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="findvideos" if "movie" in contentType else "episodios",
contentType=item.contentType,
contentTitle=scrapedtitle,
@@ -128,7 +128,7 @@ def top_imdb(item, contentType='movie', regex=r'<h1.*?TOP IMDb.*?<h3>(.*?)<h3>')
thumbnail = thumb(itemlist=[])
scrapedurl = item.url + '{}' + str(p + 1)
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
contentType=item.contentType,
action="top_imdb",
title="[COLOR blue][B]Successivo >[/B][/COLOR]",
@@ -173,7 +173,7 @@ def peliculas(item):
scrapedtitle = re.sub(r'[0-9]{4}', "", scrapedtitle)
type = "[COLOR aqua][Serie][/COLOR]" if "tvshows" in item.args else "[COLOR aqua][Film][/COLOR]"
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="episodios" if "tvshows" in item.args else "findvideos",
contentType="episode" if "tvshows" in item.args else "movie",
title=scrapedtitle + " " + "[COLOR orange][" + year + "][/COLOR]" + " " + type,
@@ -223,7 +223,7 @@ def episodios(item):
matches = re.compile(patron, re.DOTALL).findall(block)
for scrapedurl, scrapedtitle in matches:
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="videoplayer",
contentType=item.contentType,
title=scrapedtitle,
@@ -250,7 +250,7 @@ def episodios(item):
if len(matches) > 1:
for scrapedtitle, scrapedurl in matches:
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="player_list",
contentType=item.contentType,
title=scrapedtitle,
@@ -310,7 +310,7 @@ def player(item):
for scrapedurl in matches:
scrapedurl = "https://fvs.io/" + scrapedurl
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="play",
contentType=item.contentType,
title=item.title,
@@ -345,7 +345,7 @@ def player_list(item):
scrapedtitle = re.sub('Pir8|UBi|M L|BEDLAM|REPACK|DD5.1|bloody|SVU', '', scrapedtitle)
scrapedtitle = scrapedtitle.replace(".", " ").replace(" - ", " ").replace(" -", "").replace(" ", "")
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="halfplayer",
contentType=item.contentType,
title=scrapedtitle,
@@ -393,7 +393,7 @@ def dooplayer(item):
for scrapedurl in matches:
scrapedurl = "https://fvs.io/" + scrapedurl
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="play",
contentType=item.contentType,
title=item.title,
+21 -19
View File
@@ -232,27 +232,29 @@ def peliculas_tv(item):
scrapedplot = ""
scrapedtitle = cleantitle(scrapedtitle)
infoLabels = {}
episode = scrapertools.find_multiple_matches(scrapedtitle, r'((\d*)x(\d*))')[0]
title = scrapedtitle.split(" S0")[0].strip()
title = title.split(" S1")[0].strip()
title = title.split(" S2")[0].strip()
episode = scrapertools.find_multiple_matches(scrapedtitle, r'((\d*)x(\d*))')
if episode: # workaround per quando mettono le serie intere o altra roba, sarebbero da intercettare TODO
episode = episode[0]
title = scrapedtitle.split(" S0")[0].strip()
title = title.split(" S1")[0].strip()
title = title.split(" S2")[0].strip()
infoLabels['season'] = episode[1]
infoLabels['episode'] = episode[2].zfill(2)
infoLabels['season'] = episode[1]
infoLabels['episode'] = episode[2].zfill(2)
itemlist.append(
Item(channel=item.channel,
action="findvideos",
fulltitle=scrapedtitle,
show=scrapedtitle,
title=title + " - " + episode[0] + " " + support.typo("Sub-ITA", '_ [] color kod'),
url=scrapedurl,
thumbnail=scrapedthumbnail,
contentSerieName=title,
contentLanguage='Sub-ITA',
plot=scrapedplot,
infoLabels=infoLabels,
folder=True))
itemlist.append(
Item(channel=item.channel,
action="findvideos",
fulltitle=scrapedtitle,
show=scrapedtitle,
title=title + " - " + episode[0] + " " + support.typo("Sub-ITA", '_ [] color kod'),
url=scrapedurl,
thumbnail=scrapedthumbnail,
contentSerieName=title,
contentLanguage='Sub-ITA',
plot=scrapedplot,
infoLabels=infoLabels,
folder=True))
tmdb.set_infoLabels_itemlist(itemlist, seekTmdb=True)
+17 -1
View File
@@ -58,6 +58,22 @@
"enabled": true,
"visible": true,
"lvalues": ["Non filtrare","IT"]
}
},
{
"id": "autorenumber",
"type": "bool",
"label": "@70712",
"default": false,
"enabled": true,
"visible": true
},
{
"id": "autorenumber_mode",
"type": "bool",
"label": "@70688",
"default": false,
"enabled": true,
"visible": "eq(-1,true)"
}
]
}
+2 -1
View File
@@ -136,7 +136,8 @@ def peliculas(item):
else:
patron = r'<div class="media3">[^>]+><a href="([^"]+)"><img[^s]+src="([^"]+)"[^>]+><\/a><[^>]+><a[^<]+><p>([^<]+) \(([^\)]+)[^<]+<\/p>.*?<p>\s*([a-zA-Z-0-9]+)\s*<\/p>'
itemlist = support.scrape(item, patron, ['url', 'thumb', 'title', 'year', 'quality'], headers, action=action, patronNext='<a class="nextpostslink" rel="next" href="([^"]+)">')
return autorenumber.renumber(itemlist) if item.args == 'anime' else itemlist
if item.args == 'anime': autorenumber.renumber(itemlist)
return itemlist
def episodios(item):
+13 -13
View File
@@ -63,7 +63,7 @@ def insert(item):
scrapedtitle = scrapertools.decodeHtmlentities(scrapedtitle)
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="episodios",
contentType="episode",
title=scrapedtitle,
@@ -77,7 +77,7 @@ def insert(item):
if len(matches) >= p * minpage:
scrapedurl = item.url + '{}' + str(p + 1)
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
args=item.args,
action="insert",
title="[COLOR blue][B]Successivo >[/B][/COLOR]",
@@ -109,7 +109,7 @@ def updates(item):
scrapedplot = ""
scrapedtitle = scrapertools.decodeHtmlentities(scrapedtitle)
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="episodios",
contentType="episode",
title=scrapedtitle,
@@ -141,7 +141,7 @@ def most_view(item):
scrapedplot = ""
scrapedtitle = scrapertools.decodeHtmlentities(scrapedtitle)
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="episodios",
contentType="episode",
title=scrapedtitle,
@@ -177,7 +177,7 @@ def list(item):
scrapedtitle = scrapertools.decodeHtmlentities(scrapedtitle)
scrapedplot = ""
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action = 'episodios' if not 'film' in item.args else 'findvideos',
contentType=item.contentType,
title=scrapedtitle,
@@ -190,7 +190,7 @@ def list(item):
if len(matches) >= p * minpage:
scrapedurl = item.url + '{}' + str(p + 1)
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
args=item.args,
contentType=item.contentType,
action="list",
@@ -224,7 +224,7 @@ def peliculas(item):
if i >= p * minpage: break
scrapedtitle = scrapertools.decodeHtmlentities(scrapedtitle)
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="episodios",
contentType="episode",
title=scrapedtitle,
@@ -236,7 +236,7 @@ def peliculas(item):
if len(matches) >= p * minpage:
scrapedurl = item.url + '{}' + str(p + 1)
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
extra=item.extra,
action="peliculas",
title="[COLOR blue][B]Successivo >[/B][/COLOR]",
@@ -257,7 +257,7 @@ def episodios(item):
matches = re.compile(patron, re.DOTALL).findall(data)
if "https://vcrypt.net" in data:
patron = r'(?:<p>|<br />)([^<]+)<a href="([^"]+)'
patron = r'(?:<p>|<br /> )([^<]+) &#8211; <a href="([^"]+)'
matches = re.compile(patron, re.DOTALL).findall(data)
for scrapedtitle, scrapedurl in matches:
@@ -273,7 +273,7 @@ def episodios(item):
else:
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="findvideos",
contentType=item.contentType,
title="[COLOR azure]" + scrapedtitle + "[/COLOR]",
@@ -298,7 +298,7 @@ def episodios(item):
else:
itemlist.append(
Item(channel=channel,
Item(channel=__channel__,
action="findvideos",
contentType=item.contentType,
title="[COLOR azure]" + scrapedtitle + "[/COLOR]",
@@ -337,7 +337,7 @@ def findvideos(item):
itemlist = servertools.find_video_items(data=data)
for videoitem in itemlist:
videoitem.channel = channel
videoitem.channel = __channel__
server = re.sub(r'[-\[\]\s]+', '', videoitem.title)
videoitem.title = "".join(['[COLOR blue] ' + "[[B]" + server + "[/B]][/COLOR] " + item.title])
videoitem.thumbnail = item.thumbnail
@@ -349,7 +349,7 @@ def findvideos(item):
itemlist = servertools.find_video_items(data=item.url)
for videoitem in itemlist:
videoitem.channel = channel
videoitem.channel = __channel__
server = re.sub(r'[-\[\]\s]+', '', videoitem.title)
videoitem.title = "".join(['[COLOR blue] ' + "[[B]" + server + "[/B]] " + item.title + '[/COLOR]'])
videoitem.thumbnail = item.thumbnail