Compare commits
15 Commits
nuovo_upda
...
prove_inte
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
fdfaacbd4e | ||
|
|
dc96c1705d | ||
|
|
c0a5629d8f | ||
|
|
dc9f552708 | ||
|
|
746738a868 | ||
|
|
a0e45bd896 | ||
|
|
073b755100 | ||
|
|
26ac0660f7 | ||
|
|
5a2c9fb6ac | ||
|
|
b5b4427941 | ||
|
|
7ff96d2248 | ||
|
|
f544552b5f | ||
|
|
b0a4688038 | ||
|
|
4e1e761c0a | ||
|
|
f394372f78 |
@@ -1,34 +0,0 @@
|
||||
name: Update channel domains
|
||||
on:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '30 17 * * *'
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
update:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: '3.7'
|
||||
architecture: 'x64'
|
||||
|
||||
- name: Install dependencies
|
||||
run: pip install requests
|
||||
|
||||
- name: Update domains
|
||||
run: python tools/updateDomains.py
|
||||
|
||||
- name: Commit & Push changes
|
||||
uses: actions-js/push@master
|
||||
with:
|
||||
message: "Aggiornamento domini"
|
||||
branch: "master"
|
||||
github_token: ${{ secrets.API_TOKEN_GITHUB }}
|
||||
0
.github/ISSUE_TEMPLATE/canale-non-funzionante.md
vendored
Executable file → Normal file
0
.github/ISSUE_TEMPLATE/canale-non-funzionante.md
vendored
Executable file → Normal file
0
.github/ISSUE_TEMPLATE/server-non-funzionante.md
vendored
Executable file → Normal file
0
.github/ISSUE_TEMPLATE/server-non-funzionante.md
vendored
Executable file → Normal file
0
.github/ISSUE_TEMPLATE/test-canale.md
vendored
Executable file → Normal file
0
.github/ISSUE_TEMPLATE/test-canale.md
vendored
Executable file → Normal file
13
.github/workflows/tests.yml
vendored
Executable file → Normal file
13
.github/workflows/tests.yml
vendored
Executable file → Normal file
@@ -1,25 +1,28 @@
|
||||
name: Test Suite
|
||||
on:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '00 15 * * *'
|
||||
|
||||
jobs:
|
||||
tests:
|
||||
runs-on: macos-latest
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
|
||||
- uses: actions/checkout@v3
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v4.3.0
|
||||
uses: actions/setup-python@v1
|
||||
with:
|
||||
python-version: 3.9
|
||||
python-version: 3.8
|
||||
|
||||
- name: Run tests
|
||||
run: |
|
||||
export KODI_INTERACTIVE=0
|
||||
./tests/run.sh
|
||||
|
||||
- name: Commit & Push changes
|
||||
uses: dmnemec/copy_file_to_another_repo_action@main
|
||||
uses: dmnemec/copy_file_to_another_repo_action@v1.0.4
|
||||
env:
|
||||
API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }}
|
||||
with:
|
||||
|
||||
0
.github/workflows/updateDomains.yml
vendored
Executable file → Normal file
0
.github/workflows/updateDomains.yml
vendored
Executable file → Normal file
0
.github/workflows/updateDomainsStable.yml
vendored
Executable file → Normal file
0
.github/workflows/updateDomainsStable.yml
vendored
Executable file → Normal file
2
.gitignore
vendored
Executable file → Normal file
2
.gitignore
vendored
Executable file → Normal file
@@ -9,5 +9,3 @@ __pycache__/
|
||||
.vscode/settings.json
|
||||
bin/
|
||||
lib/abi
|
||||
tests/home/
|
||||
reports/
|
||||
0
CONTRIBUTING.md
Executable file → Normal file
0
CONTRIBUTING.md
Executable file → Normal file
0
__init__.py
Executable file → Normal file
0
__init__.py
Executable file → Normal file
12
addon.xml
Executable file → Normal file
12
addon.xml
Executable file → Normal file
@@ -1,10 +1,11 @@
|
||||
<addon id="plugin.video.kod" name="Kodi on Demand" version="1.7.7" provider-name="KoD Team">
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||
<addon id="plugin.video.kod" name="Kodi on Demand BETA" version="1.7.6" provider-name="KoD Team">
|
||||
<requires>
|
||||
<!-- <import addon="script.module.libtorrent" optional="true"/> -->
|
||||
<import addon="metadata.themoviedb.org" optional="true"/>
|
||||
<import addon="metadata.tvshows.themoviedb.org" optional="true"/>
|
||||
<import addon="metadata.themoviedb.org"/>
|
||||
<import addon="metadata.tvshows.themoviedb.org"/>
|
||||
<!-- <import addon="metadata.tvdb.com"/> -->
|
||||
|
||||
<import addon="script.module.web-pdb" />
|
||||
</requires>
|
||||
<extension point="xbmc.python.pluginsource" library="default.py">
|
||||
<provides>video</provides>
|
||||
@@ -28,6 +29,9 @@
|
||||
<screenshot>resources/media/screenshot-3.png</screenshot>
|
||||
</assets>
|
||||
<news>- fix di routine ai canali/server
|
||||
- disabilitati cb01anime e tantifilm
|
||||
- aggiunta opzione "mostra server" nel menu contestuale della libreria
|
||||
- più opzioni per quanto riguarda l'aggiornamento della videoteca
|
||||
</news>
|
||||
<description lang="it">Naviga velocemente sul web e guarda i contenuti presenti</description>
|
||||
<disclaimer>[COLOR red]The owners and submitters to this addon do not host or distribute any of the content displayed by these addons nor do they have any affiliation with the content providers.[/COLOR]
|
||||
|
||||
44
channels.json
Executable file → Normal file
44
channels.json
Executable file → Normal file
@@ -1,38 +1,38 @@
|
||||
{
|
||||
"direct": {
|
||||
"altadefinizione01": "https://altadefinizione01.pet",
|
||||
"animealtadefinizione": "http://ww38.animealtadefinizione.it",
|
||||
"altadefinizione01": "https://www.altadefinizione01.sbs",
|
||||
"animealtadefinizione": "https://www.animealtadefinizione.it",
|
||||
"animeforce": "https://www.animeforce.it",
|
||||
"animesaturn": "https://www.animesaturn.cx",
|
||||
"animesaturn": "https://www.animesaturn.in",
|
||||
"animeunity": "https://www.animeunity.tv",
|
||||
"animeworld": "https://www.animeworld.so",
|
||||
"aniplay": "https://aniplay.co",
|
||||
"casacinema": "https://casacinema.media",
|
||||
"cb01anime": "https://cb01new.one",
|
||||
"animeuniverse": "https://www.animeuniverse.it",
|
||||
"animeworld": "https://www.animeworld.tv",
|
||||
"aniplay": "https://aniplay.it",
|
||||
"casacinema": "https://www.casacinema.lol",
|
||||
"cb01anime": "https://www.cineblog01.red",
|
||||
"cinemalibero": "https://cinemalibero.cafe",
|
||||
"cinetecadibologna": "http://cinestore.cinetecadibologna.it",
|
||||
"dinostreaming": "https://dinostreaming.it",
|
||||
"discoveryplus": "https://www.discoveryplus.com",
|
||||
"dreamsub": "https://www.animeworld.so",
|
||||
"eurostreaming": "https://eurostreaming.lifestyle",
|
||||
"eurostreaming_actor": "https://eurostreaming.my",
|
||||
"filmstreaming": "https://film-streaming-ita.cam",
|
||||
"guardaseriecam": "https://guardaserie.kitchen",
|
||||
"dreamsub": "https://www.animeworld.tv",
|
||||
"eurostreaming": "https://eurostreaming.party",
|
||||
"eurostreaming_actor": "https://eurostreaming.actor",
|
||||
"filmstreaming": "https://filmstreaming.media",
|
||||
"guardaseriecam": "https://guardaserie.cam",
|
||||
"hd4me": "https://hd4me.net",
|
||||
"ilcorsaronero": "https://ilcorsaronero.link",
|
||||
"ilgeniodellostreaming_cam": "https://ilgeniodellostreaming.foo",
|
||||
"italiafilm": "https://italia-film.biz",
|
||||
"ilgeniodellostreaming_cam": "https://ilgeniodellostreaming.sbs",
|
||||
"mediasetplay": "https://mediasetinfinity.mediaset.it",
|
||||
"mondoserietv": "http://ww25.mondoserietv.club/?subid1=20230304-0434-261c-9cb0-a0044930e0a9",
|
||||
"mondoserietv": "https://mondoserietv.club",
|
||||
"paramount": "https://www.mtv.it",
|
||||
"piratestreaming": "https://piratestreaming.design",
|
||||
"piratestreaming": "https://www.piratestreaming.design",
|
||||
"plutotv": "https://pluto.tv",
|
||||
"raiplay": "https://www.raiplay.it",
|
||||
"serietvu": "http://ww1.serietvu.live/?sub1=47fb879a-5325-11ee-94a7-cc35006f53d1",
|
||||
"streamingcommunity": "https://streamingcommunity.ooo",
|
||||
"streamingita": "https://streamingita.click",
|
||||
"tantifilm": "https://tantifilm.name",
|
||||
"toonitalia": "https://toonitalia.xyz"
|
||||
"serietvu": "https://www.serietvu.live",
|
||||
"streamingcommunity": "https://streamingcommunity.tech",
|
||||
"streamingita": "https://www.streamingita.wtf",
|
||||
"streamtime": "https://t.me/s/StreamTime",
|
||||
"tantifilm": "https://www.tantifilm.yachts",
|
||||
"toonitalia": "https://toonitalia.co"
|
||||
},
|
||||
"findhost": {
|
||||
"altadefinizione": "https://altadefinizione.nuovo.live",
|
||||
|
||||
0
channels/0example.json.txt
Executable file → Normal file
0
channels/0example.json.txt
Executable file → Normal file
0
channels/0example.py.txt
Executable file → Normal file
0
channels/0example.py.txt
Executable file → Normal file
1
channels/1337x.json
Executable file → Normal file
1
channels/1337x.json
Executable file → Normal file
@@ -6,7 +6,6 @@
|
||||
"thumbnail": "1337x.png",
|
||||
"banner": "1337x.png",
|
||||
"categories": ["movie", "tvshow", "torrent"],
|
||||
"not_active": ["include_in_newest"],
|
||||
"settings": [
|
||||
{
|
||||
"id": "itaSearch",
|
||||
|
||||
4
channels/1337x.py
Executable file → Normal file
4
channels/1337x.py
Executable file → Normal file
@@ -103,13 +103,13 @@ def peliculas(item):
|
||||
data = ' '
|
||||
else:
|
||||
data = support.match(item).data
|
||||
# debug = True
|
||||
|
||||
if item.args == 'search':
|
||||
sceneTitle = 'undefined'
|
||||
patron = r'<a href="(?P<url>[^"]+)">(?P<title>[^<]+)<(?:[^>]+>){3,7}(?P<seed>[^<]+)<(?:[^>]+>){6}(?P<size>[^<]+)<span'
|
||||
patronNext = r'"([^"]+)">>>'
|
||||
elif item.contentType == 'movie':
|
||||
patron = r'<img[^>]+data-original="(?P<thumb>[^"]+)(?:[^>]+>){15}(?P<title>[^<]+).*?<p>(?P<plot>[^<]+).*?<a href="(?P<url>[^"]+)'
|
||||
patron = r'<img alt="[^"]*" data-original="(?P<thumb>[^"]+)(?:[^>]+>){15}(?P<title>[^<]+)(?:[^>]+>){18,23}\s*<a href="(?P<url>[^"]+)'
|
||||
patronNext = r'"([^"]+)">>>'
|
||||
else:
|
||||
action = 'seasons'
|
||||
|
||||
0
channels/__init__.py
Executable file → Normal file
0
channels/__init__.py
Executable file → Normal file
0
channels/accuradio.json
Executable file → Normal file
0
channels/accuradio.json
Executable file → Normal file
3
channels/accuradio.py
Executable file → Normal file
3
channels/accuradio.py
Executable file → Normal file
@@ -35,9 +35,8 @@ def mainlist(item):
|
||||
|
||||
@support.scrape
|
||||
def peliculas(item):
|
||||
# debug=True
|
||||
action = 'playradio'
|
||||
patron = r'data-id="(?P<id>[^"]+)"\s*data-oldid="(?P<oldid>[^"]+)".*?data-name="(?P<title>[^"]+)(?:[^>]+>){2}<img src="(?P<thumb>[^"]+)(?:[^>]+>){16}\s*(?P<plot>[^<]+)'
|
||||
patron = r'data-id="(?P<id>[^"]+)"\s*data-oldid="(?P<oldid>[^"]+)".*?data-name="(?P<title>[^"]+)(?:[^>]+>){5}<img class="[^"]+"\s*src="(?P<thumb>[^"]+)(?:[^>]+>){6}\s*(?P<plot>[^<]+)'
|
||||
return locals()
|
||||
|
||||
|
||||
|
||||
3
channels/altadefinizione.json
Executable file → Normal file
3
channels/altadefinizione.json
Executable file → Normal file
@@ -6,6 +6,5 @@
|
||||
"thumbnail": "altadefinizione.png",
|
||||
"banner": "altadefinizione.png",
|
||||
"categories": ["movie", "tvshow", "vos"],
|
||||
"settings": [],
|
||||
"not_active": ["include_in_newest"]
|
||||
"settings": []
|
||||
}
|
||||
|
||||
116
channels/altadefinizione.py
Executable file → Normal file
116
channels/altadefinizione.py
Executable file → Normal file
@@ -4,59 +4,53 @@
|
||||
# ------------------------------------------------------------
|
||||
|
||||
|
||||
from core import httptools, support, tmdb, scrapertools
|
||||
from core import httptools, support
|
||||
from platformcode import config, logger
|
||||
import re
|
||||
|
||||
|
||||
def findhost(url):
|
||||
host = support.match(url, patron=r'<h2[^>]+><a href="([^"]+)').match.rstrip('/')
|
||||
permUrl = httptools.downloadpage(host, follow_redirects=False, only_headers=True).headers
|
||||
|
||||
if 'location' in permUrl.keys(): # handle redirection
|
||||
return permUrl['location']
|
||||
return host
|
||||
|
||||
|
||||
host = config.get_channel_url(findhost)
|
||||
headers = [['Referer', host]]
|
||||
|
||||
|
||||
@support.menu
|
||||
def mainlist(item):
|
||||
menu = [('Film',['/category/film/', 'peliculas', '', 'movie']),
|
||||
('Film al cinema {submenu}',['/category/ora-al-cinema/', 'peliculas', '', 'movie']),
|
||||
('Generi',['', 'genres', '', 'undefined']),
|
||||
('Saghe',['', 'genres', 'saghe', 'undefined']),
|
||||
('Serie TV',['/category/serie-tv/', 'peliculas', '', 'tvshow']),
|
||||
#('Aggiornamenti Serie TV', ['/aggiornamenti-serie-tv/', 'peliculas']) da fixare
|
||||
|
||||
film = ['/category/film/',
|
||||
('Al Cinema', ['/al-cinema/', 'peliculas']),
|
||||
('Generi', ['', 'genres']),
|
||||
# ('Sub-ITA', ['/sub-ita/', 'peliculas'])
|
||||
]
|
||||
|
||||
tvshow = ['/category/serie-tv/',
|
||||
('Aggiornamenti Serie TV', ['/aggiornamenti-serie-tv/', 'peliculas']),]
|
||||
|
||||
search = ''
|
||||
|
||||
return locals()
|
||||
|
||||
|
||||
@support.scrape
|
||||
def genres(item):
|
||||
action = 'peliculas'
|
||||
blacklist = ['Scegli il Genere', 'Film', 'Serie Tv', 'Sub-Ita', 'Anime', "Non reperibile", 'Anime Sub-ITA', 'Prossimamente',]
|
||||
wantSaga = True if item.args == 'saghe' else False
|
||||
|
||||
patronBlock = r'<div class=\"categories-buttons-container\"(?P<block>.*?)</div>'
|
||||
if not wantSaga: # se non richiedo le sage carico le icone in automatico
|
||||
patronMenu = r'<a href=\"(?P<url>https:\/\/.*?)\".*?>(?P<title>.*?)</a>'
|
||||
else: # mantengo l'icona del padre
|
||||
patron = r'<a href=\"(?P<url>https:\/\/.*?)\".*?>(?P<title>.*?)</a>'
|
||||
|
||||
blacklist = ['Scegli il Genere', 'Film', 'Serie TV', 'Sub-Ita', 'Anime']
|
||||
patronMenu = r'<option value="(?P<url>[^"]+)">(?P<title>[^<]+)'
|
||||
def itemlistHook(itemlist):
|
||||
itl = []
|
||||
for item in itemlist:
|
||||
isSaga = item.fulltitle.startswith('Saga')
|
||||
|
||||
if len(item.fulltitle) != 3:
|
||||
if (isSaga and wantSaga) or (not isSaga and not wantSaga):
|
||||
itl.append(item)
|
||||
itl.append(item)
|
||||
return itl
|
||||
return locals()
|
||||
|
||||
|
||||
def search(item, text):
|
||||
item.url = "{}/?{}".format(host, support.urlencode({'s': text}))
|
||||
logger.debug(text)
|
||||
item.url = "{}/search/{}/feed/rss2/".format(host, text)
|
||||
item.args = 'search'
|
||||
|
||||
try:
|
||||
@@ -68,54 +62,33 @@ def search(item, text):
|
||||
logger.error("search except: %s" % line)
|
||||
return []
|
||||
|
||||
|
||||
@support.scrape
|
||||
def peliculas(item):
|
||||
if not item.args == 'search': # pagination not works
|
||||
if not item.nextpage:
|
||||
item.page = 1
|
||||
else:
|
||||
item.page = item.nextpage
|
||||
|
||||
if not item.parent_url:
|
||||
item.parent_url = item.url
|
||||
|
||||
item.nextpage = item.page + 1
|
||||
nextPageUrl = "{}/page/{}".format(item.parent_url, item.nextpage)
|
||||
resp = httptools.downloadpage(nextPageUrl, only_headers = True)
|
||||
if (resp.code > 399): # no more elements
|
||||
nextPageUrl = ''
|
||||
else:
|
||||
action = 'check'
|
||||
|
||||
patron= r'<article class=\"elementor-post.*?(<img .*?src=\"(?P<thumb>[^\"]+).*?)?<h1 class=\"elementor-post__title\".*?<a href=\"(?P<url>[^\"]+)\" >\s*(?P<title>[^<]+?)\s*(\((?P<lang>Sub-[a-zA-Z]+)*\))?\s*(\[(?P<quality>[A-Z]*)\])?\s*(\((?P<year>[0-9]{4})\))?\s+<'
|
||||
|
||||
n = '22' if '/?s=' in item.url else '8'
|
||||
item.contentType = "undefined"
|
||||
action = 'check'
|
||||
patron = r'src="(?P<poster>http[^"]+)(?:[^>]+>){4}\s*<a href="(?P<url>[^"]+)[^>]+>\s*(?P<title>[^\[\(\<]+)(?:\[(?P<quality>[^\]]+)\])?\s*(?:\((?P<lang>[a-zA-z-]+)\))?\s*(?:\((?P<year>\d+)\))?\s*</a>\s*</h2>'
|
||||
if item.args == 'search':
|
||||
patron = r'<title>(?P<title>[^\[\(\<]+)(?:\[(?P<quality>[^\]]+)\])?\s*(?:\((?P<lang>[a-zA-z-]+)\))?\s*(?:\((?P<year>\d+)\))?\s*[^>]+>\s*<link>(?P<url>[^<]+)'
|
||||
patronNext = r'href="([^"]+)[^>]+>Successivo'
|
||||
return locals()
|
||||
|
||||
|
||||
@support.scrape
|
||||
def episodios(item):
|
||||
item.quality = ''
|
||||
data = item.data if item.data else httptools.downloadpage(item.url).data
|
||||
itemlist = []
|
||||
data = item.data
|
||||
action='findvideos'
|
||||
# debug=True
|
||||
patronBlock = r'<span>\s*\w+\s*[Ss]tagione.*?(?P<lang>(?:[Ss][Uu][Bb][-]?)?[Ii][Tt][Aa])(?: in )?(?P<quality>[^<]*)?(?:[^>]+>){4}(?P<block>.*?)/p>'
|
||||
patron = r'(?P<season>\d+)x(?P<episode>\d+)[^>]+>(?P<data>.*?)(?:</table)'
|
||||
return locals()
|
||||
|
||||
for it in support.match(data, patron=[r'div class=\"single-season.*?(?P<id>season_[0-9]+).*?>Stagione:\s(?P<season>[0-9]+).*?(\s-\s(?P<lang>[a-zA-z]+?))?<']).matches:
|
||||
block = support.match(data, patron = r'div id=\"'+ it[0] +'\".*?</div').match
|
||||
for ep in support.match(block, patron=[r'<li><a href=\"(?P<url>[^\"]+).*?img\" src=\"(?P<thumb>[^\"]+).*?title\">(?P<episode>[0-9]+)\.\s+(?P<title>.*?)</span>']).matches:
|
||||
itemlist.append(item.clone(contentType = 'episode',
|
||||
action='findvideos',
|
||||
thumb = ep[1],
|
||||
title = support.format_longtitle(support.cleantitle(ep[3]), season = it[1], episode = ep[2], lang= it[3]),
|
||||
url = ep[0], data = '')
|
||||
)
|
||||
|
||||
support.check_trakt(itemlist)
|
||||
support.videolibrary(itemlist, item)
|
||||
if (config.get_setting('downloadenabled')):
|
||||
support.download(itemlist, item)
|
||||
|
||||
return itemlist
|
||||
|
||||
def check(item):
|
||||
item.data = httptools.downloadpage(item.url).data
|
||||
if 'season-details' in item.data.lower():
|
||||
if 'Stagione' in item.data:
|
||||
item.contentType = 'tvshow'
|
||||
return episodios(item)
|
||||
else:
|
||||
@@ -123,14 +96,7 @@ def check(item):
|
||||
|
||||
|
||||
def findvideos(item):
|
||||
video_url = item.url
|
||||
|
||||
if item.contentType == 'movie':
|
||||
video_url = support.match(item, patron=[r'<div class="video-wrapper">.*?<iframe src=\"(https://.*?)\"',
|
||||
r'window.open\(\'([^\']+).*?_blank']).match
|
||||
if (video_url == ''):
|
||||
return []
|
||||
itemlist = [item.clone(action="play", url=srv) for srv in support.match(video_url, patron='<div class="megaButton" meta-type="v" meta-link="([^"]+).*?(?=>)>').matches]
|
||||
itemlist = support.server(item,itemlist=itemlist)
|
||||
|
||||
return itemlist
|
||||
logger.debug()
|
||||
if item.contentType == 'movie' and isinstance(item.data, str):
|
||||
item.data = support.match(item.data, patron=r'data-id="([^"]+)').matches
|
||||
return support.server(item, item.data)
|
||||
|
||||
0
channels/altadefinizione01.json
Executable file → Normal file
0
channels/altadefinizione01.json
Executable file → Normal file
14
channels/altadefinizione01.py
Executable file → Normal file
14
channels/altadefinizione01.py
Executable file → Normal file
@@ -141,17 +141,13 @@ def newest(categoria):
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def findvideos(item):
|
||||
support.info('findvideos', item)
|
||||
data = httptools.downloadpage(item.url).data
|
||||
iframe = support.match(data, patron='src="(http[^"]+)" frameborder=\"0\" allow=\"accelerometer; autoplay;').match
|
||||
iframe = support.match(data, patron='src="(http[^"]+)" frameborder').match
|
||||
if iframe:
|
||||
item.url = iframe
|
||||
return support.server(item)
|
||||
|
||||
# TODO: verificare se si puo' reinsierire il trailer youtube
|
||||
#itemlist = [item.clone(action="play", url=srv[0], quality=srv[1]) for srv in support.match(item, patron='<a href="#" data-link="([^"]+).*?<span class="d">([^<]+)').matches]
|
||||
#itemlist = support.server(item, itemlist=itemlist, headers=headers)
|
||||
|
||||
#return itemlist
|
||||
return support.server(item)
|
||||
else:
|
||||
itemlist = [item.clone(action="play", url=srv[0], quality=srv[1]) for srv in support.match(item, patron='<a href="#" data-link="([^"]+).*?<span class="d">([^<]+)').matches]
|
||||
return support.server(item, itemlist=itemlist, headers=headers)
|
||||
|
||||
0
channels/altadefinizioneclick.json
Executable file → Normal file
0
channels/altadefinizioneclick.json
Executable file → Normal file
0
channels/altadefinizioneclick.py
Executable file → Normal file
0
channels/altadefinizioneclick.py
Executable file → Normal file
0
channels/altadefinizionecommunity.json
Executable file → Normal file
0
channels/altadefinizionecommunity.json
Executable file → Normal file
0
channels/altadefinizionecommunity.py
Executable file → Normal file
0
channels/altadefinizionecommunity.py
Executable file → Normal file
2
channels/animealtadefinizione.json
Executable file → Normal file
2
channels/animealtadefinizione.json
Executable file → Normal file
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"id": "animealtadefinizione",
|
||||
"name": "AnimealtAdefinizione",
|
||||
"active": false,
|
||||
"active": true,
|
||||
"language": ["ita", "sub-ita"],
|
||||
"thumbnail": "animealtadefinizione.png",
|
||||
"banner": "animealtadefinizione.png",
|
||||
|
||||
0
channels/animealtadefinizione.py
Executable file → Normal file
0
channels/animealtadefinizione.py
Executable file → Normal file
2
channels/animeforce.json
Executable file → Normal file
2
channels/animeforce.json
Executable file → Normal file
@@ -2,7 +2,7 @@
|
||||
"id": "animeforce",
|
||||
"name": "AnimeForce",
|
||||
"language": ["ita"],
|
||||
"active": false,
|
||||
"active": true,
|
||||
"thumbnail": "animeforce.png",
|
||||
"banner": "animeforce.png",
|
||||
"categories": ["anime"],
|
||||
|
||||
0
channels/animeforce.py
Executable file → Normal file
0
channels/animeforce.py
Executable file → Normal file
0
channels/animesaturn.json
Executable file → Normal file
0
channels/animesaturn.json
Executable file → Normal file
5
channels/animesaturn.py
Executable file → Normal file
5
channels/animesaturn.py
Executable file → Normal file
@@ -3,7 +3,10 @@
|
||||
# Canale per AnimeSaturn
|
||||
# ----------------------------------------------------------
|
||||
|
||||
from lib import js2py
|
||||
from core import support
|
||||
from platformcode import config
|
||||
from platformcode.logger import debug
|
||||
|
||||
host = support.config.get_channel_url()
|
||||
__channel__ = 'animesaturn'
|
||||
@@ -143,7 +146,7 @@ def peliculas(item):
|
||||
return itemlist
|
||||
|
||||
else:
|
||||
# pagination = ''
|
||||
pagination = ''
|
||||
if item.args == 'incorso':
|
||||
patron = r'<a href="(?P<url>[^"]+)"[^>]+>(?P<title>[^<(]+)(?:\s*\((?P<year>\d+)\))?(?:\s*\((?P<lang>[A-za-z-]+)\))?</a>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>\s*<img width="[^"]+" height="[^"]+" src="(?P<thumb>[^"]+)"[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>(?P<plot>[^<]+)<'
|
||||
else:
|
||||
|
||||
0
channels/animeunity.json
Executable file → Normal file
0
channels/animeunity.json
Executable file → Normal file
110
channels/animeunity.py
Executable file → Normal file
110
channels/animeunity.py
Executable file → Normal file
@@ -4,13 +4,14 @@
|
||||
# ------------------------------------------------------------
|
||||
|
||||
import cloudscraper, json, copy, inspect
|
||||
from core import jsontools, support, httptools, scrapertools
|
||||
from platformcode import autorenumber
|
||||
from core import support
|
||||
from platformcode import autorenumber, logger
|
||||
|
||||
session = cloudscraper.create_scraper()
|
||||
|
||||
# support.dbg()
|
||||
host = support.config.get_channel_url()
|
||||
response = httptools.downloadpage(host + '/archivio')
|
||||
csrf_token = support.match(response.data, patron='name="csrf-token" content="([^"]+)"').match
|
||||
response = session.get(host + '/archivio')
|
||||
csrf_token = support.match(response.text, patron='name="csrf-token" content="([^"]+)"').match
|
||||
headers = {'content-type': 'application/json;charset=UTF-8',
|
||||
'x-csrf-token': csrf_token,
|
||||
'Cookie' : '; '.join([x.name + '=' + x.value for x in response.cookies])}
|
||||
@@ -53,7 +54,7 @@ def genres(item):
|
||||
# support.dbg()
|
||||
itemlist = []
|
||||
|
||||
genres = json.loads(support.match(response.data, patron='genres="([^"]+)').match.replace('"','"'))
|
||||
genres = json.loads(support.match(response.text, patron='genres="([^"]+)').match.replace('"','"'))
|
||||
|
||||
for genre in genres:
|
||||
item.args['genres'] = [genre]
|
||||
@@ -65,10 +66,10 @@ def years(item):
|
||||
itemlist = []
|
||||
|
||||
from datetime import datetime
|
||||
next_year = datetime.today().year + 1
|
||||
oldest_year = int(support.match(response.data, patron='anime_oldest_date="([^"]+)').match)
|
||||
current_year = datetime.today().year
|
||||
oldest_year = int(support.match(response.text, patron='anime_oldest_date="([^"]+)').match)
|
||||
|
||||
for year in list(reversed(range(oldest_year, next_year + 1))):
|
||||
for year in list(reversed(range(oldest_year, current_year + 1))):
|
||||
item.args['year']=year
|
||||
itemlist.append(item.clone(title=support.typo(year,'bold'), action='peliculas'))
|
||||
return itemlist
|
||||
@@ -116,34 +117,23 @@ def news(item):
|
||||
support.info()
|
||||
item.contentType = 'episode'
|
||||
itemlist = []
|
||||
import cloudscraper
|
||||
session = cloudscraper.create_scraper()
|
||||
|
||||
fullJs = json.loads(support.match(httptools.downloadpage(item.url).data, headers=headers, patron=r'items-json="([^"]+)"').match.replace('"','"'))
|
||||
fullJs = json.loads(support.match(session.get(item.url).text, headers=headers, patron=r'items-json="([^"]+)"').match.replace('"','"'))
|
||||
js = fullJs['data']
|
||||
|
||||
for it in js:
|
||||
if it.get('anime', {}).get('title') or it.get('anime', {}).get('title_eng'):
|
||||
title_name = it['anime']['title'] if it.get('anime', {}).get('title') else it['anime']['title_eng']
|
||||
pattern = r'[sS](?P<season>\d+)[eE](?P<episode>\d+)'
|
||||
match = scrapertools.find_single_match(it['file_name'], pattern)
|
||||
full_episode = ''
|
||||
if match:
|
||||
season, episode = match
|
||||
full_episode = ' - S' + season + ' E' + episode
|
||||
else:
|
||||
pattern = r'[._\s]Ep[._\s]*(?P<episode>\d+)'
|
||||
episode = scrapertools.find_single_match(it['file_name'], pattern)
|
||||
if episode:
|
||||
full_episode = ' - E' + episode
|
||||
itemlist.append(
|
||||
item.clone(title = support.typo(title_name + full_episode, 'bold'),
|
||||
fulltitle = it['anime']['title'],
|
||||
thumbnail = it['anime']['imageurl'],
|
||||
forcethumb = True,
|
||||
scws_id = it.get('scws_id', ''),
|
||||
url = '{}/anime/{}-{}'.format(item.url, it['anime']['id'],it['anime']['slug']),
|
||||
plot = it['anime']['plot'],
|
||||
action = 'findvideos')
|
||||
)
|
||||
itemlist.append(
|
||||
item.clone(title= support.typo(it['anime']['title'] + ' - EP. ' + it['number'], 'bold'),
|
||||
fulltitle=it['anime']['title'],
|
||||
thumbnail=it['anime']['imageurl'],
|
||||
forcethumb = True,
|
||||
scws_id=it.get('scws_id', ''),
|
||||
video_url=it.get('link', ''),
|
||||
plot=it['anime']['plot'],
|
||||
action='findvideos')
|
||||
)
|
||||
if 'next_page_url' in fullJs:
|
||||
itemlist.append(item.clone(title=support.typo(support.config.get_localized_string(30992), 'color kod bold'),thumbnail=support.thumb(), url=fullJs['next_page_url']))
|
||||
return itemlist
|
||||
@@ -162,27 +152,21 @@ def peliculas(item):
|
||||
item.args['order'] = order_list[order]
|
||||
|
||||
payload = json.dumps(item.args)
|
||||
records = httptools.downloadpage(host + '/archivio/get-animes', headers=headers, post=payload).json['records']
|
||||
# support.dbg()
|
||||
records = session.post(host + '/archivio/get-animes', headers=headers, data=payload).json()['records']
|
||||
|
||||
for it in records:
|
||||
if not it['title']:
|
||||
it['title'] = ''
|
||||
lang = support.match(it['title'], patron=r'\(([It][Tt][Aa])\)').match
|
||||
title = support.re.sub(r'\s*\([^\)]+\)', '', it['title'])
|
||||
|
||||
if 'ita' in lang.lower(): language = 'ITA'
|
||||
else: language = 'Sub-ITA'
|
||||
|
||||
if title:
|
||||
itm = item.clone(title=support.typo(title,'bold') + support.typo(language,'_ [] color kod') + (support.typo(it['title_eng'],'_ ()') if it['title_eng'] else ''))
|
||||
else:
|
||||
itm = item.clone(title=support.typo(it['title_eng'],'bold') + support.typo(language,'_ [] color kod'))
|
||||
itm = item.clone(title=support.typo(title,'bold') + support.typo(language,'_ [] color kod') + (support.typo(it['title_eng'],'_ ()') if it['title_eng'] else ''))
|
||||
itm.contentLanguage = language
|
||||
itm.type = it['type']
|
||||
itm.thumbnail = it['imageurl']
|
||||
itm.plot = it['plot']
|
||||
itm.url = '{}/anime/{}-{}'.format(item.url, it.get('id'), it.get('slug'))
|
||||
itm.url = item.url
|
||||
|
||||
if it['episodes_count'] == 1:
|
||||
itm.contentType = 'movie'
|
||||
@@ -190,7 +174,7 @@ def peliculas(item):
|
||||
itm.contentSerieName = ''
|
||||
itm.action = 'findvideos'
|
||||
itm.scws_id = it['episodes'][0].get('scws_id', '')
|
||||
# itm.video_url = it['episodes'][0].get('link', '')
|
||||
itm.video_url = it['episodes'][0].get('link', '')
|
||||
|
||||
else:
|
||||
itm.contentType = 'tvshow'
|
||||
@@ -210,10 +194,11 @@ def peliculas(item):
|
||||
def episodios(item):
|
||||
support.info()
|
||||
itemlist = []
|
||||
title = 'Parte' if item.type.lower() == 'movie' else 'Episodio'
|
||||
title = 'Parte ' if item.type.lower() == 'movie' else 'Episodio '
|
||||
|
||||
for it in item.episodes:
|
||||
itemlist.append(
|
||||
item.clone(title=support.typo('{}. {} {}'.format(it['number'], title, it['number']), 'bold'),
|
||||
item.clone(title=support.typo(title + it['number'], 'bold'),
|
||||
episode = it['number'],
|
||||
fulltitle=item.title,
|
||||
show=item.title,
|
||||
@@ -223,10 +208,8 @@ def episodios(item):
|
||||
plot=item.plot,
|
||||
action='findvideos',
|
||||
contentType='episode',
|
||||
url = '{}/{}'.format(item.url, it['id'])
|
||||
)
|
||||
# video_url=it.get('link', ''))
|
||||
)
|
||||
scws_id=it.get('scws_id', ''),
|
||||
video_url=it.get('link', '')))
|
||||
|
||||
if inspect.stack(0)[1][3] not in ['find_episodes']:
|
||||
autorenumber.start(itemlist, item)
|
||||
@@ -236,33 +219,6 @@ def episodios(item):
|
||||
|
||||
|
||||
def findvideos(item):
|
||||
# if item.scws_id:
|
||||
# from time import time
|
||||
# from base64 import b64encode
|
||||
# from hashlib import md5
|
||||
#
|
||||
# client_ip = support.httptools.downloadpage('http://ip-api.com/json/').json.get('query')
|
||||
#
|
||||
# expires = int(time() + 172800)
|
||||
# token = b64encode(md5('{}{} Yc8U6r8KjAKAepEA'.format(expires, client_ip).encode('utf-8')).digest()).decode('utf-8').replace('=', '').replace('+', '-').replace('/', '_')
|
||||
#
|
||||
# url = 'https://scws.work/master/{}?token={}&expires={}&n=1'.format(item.scws_id, token, expires)
|
||||
#
|
||||
# itemlist = [item.clone(title=support.config.get_localized_string(30137), url=url, server='directo', action='play')]
|
||||
|
||||
from core import channeltools
|
||||
itemlist = [item.clone(title=channeltools.get_channel_parameters(item.channel)['title'],
|
||||
url=item.url, server='streamingcommunityws')]
|
||||
itemlist = [item.clone(title=support.config.get_localized_string(30137), server='streamingcommunityws', url=str(item.scws_id))]
|
||||
return support.server(item, itemlist=itemlist, referer=False)
|
||||
|
||||
# return support.server(item, itemlist=itemlist)
|
||||
|
||||
#
|
||||
# def play(item):
|
||||
# urls = list()
|
||||
# info = support.match(item.url, patron=r'(http.*?rendition=(\d+)[^\s]+)').matches
|
||||
#
|
||||
# if info:
|
||||
# for url, res in info:
|
||||
# urls.append(['hls [{}]'.format(res), url])
|
||||
# return urls
|
||||
|
||||
4
channels/animeuniverse.json
Executable file → Normal file
4
channels/animeuniverse.json
Executable file → Normal file
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"id": "animeuniverse",
|
||||
"name": "AnimeHDitalia",
|
||||
"active": false,
|
||||
"name": "AnimeUniverse",
|
||||
"active": true,
|
||||
"language": ["ita", "sub-ita"],
|
||||
"thumbnail": "animeuniverse.png",
|
||||
"banner": "animeuniverse.png",
|
||||
|
||||
3
channels/animeuniverse.py
Executable file → Normal file
3
channels/animeuniverse.py
Executable file → Normal file
@@ -10,7 +10,7 @@ headers = {}
|
||||
|
||||
perpage_list = ['20','30','40','50','60','70','80','90','100']
|
||||
perpage = perpage_list[support.config.get_setting('perpage' , 'animeuniverse')]
|
||||
epPatron = r'<td>\s*(?P<title>[^<]+)[^>]+>[^>]+>\s*<a href="(?P<url>[^"]+)"[^>]+>\s*<img [^>]+Streaming'
|
||||
epPatron = r'<td>\s*(?P<title>[^<]+)[^>]+>[^>]+>\s*<a href="(?P<url>[^"]+)"'
|
||||
|
||||
|
||||
@support.menu
|
||||
@@ -103,7 +103,6 @@ def episodios(item):
|
||||
anime = True
|
||||
pagination = int(perpage)
|
||||
patron = epPatron
|
||||
# debug = True
|
||||
return locals()
|
||||
|
||||
|
||||
|
||||
9
channels/animeworld.json
Executable file → Normal file
9
channels/animeworld.json
Executable file → Normal file
@@ -7,15 +7,6 @@
|
||||
"banner": "animeworld.png",
|
||||
"categories": ["anime", "vos"],
|
||||
"settings": [
|
||||
{
|
||||
"id": "lang",
|
||||
"type": "list",
|
||||
"label": "Lingua di Ricerca",
|
||||
"default": 0,
|
||||
"enabled": true,
|
||||
"visible": true,
|
||||
"lvalues": [ "Tutte", "Ita", "Sub-Ita"]
|
||||
},
|
||||
{
|
||||
"id": "order",
|
||||
"type": "list",
|
||||
|
||||
29
channels/animeworld.py
Executable file → Normal file
29
channels/animeworld.py
Executable file → Normal file
@@ -4,7 +4,7 @@
|
||||
# thanks to fatshotty
|
||||
# ----------------------------------------------------------
|
||||
|
||||
from core import httptools, support, config, jsontools
|
||||
from core import httptools, support, jsontools
|
||||
|
||||
host = support.config.get_channel_url()
|
||||
__channel__ = 'animeworld'
|
||||
@@ -23,7 +23,7 @@ def get_data(item):
|
||||
# support.dbg()
|
||||
url = httptools.downloadpage(item.url, headers=headers, follow_redirects=True, only_headers=True).url
|
||||
data = support.match(url, headers=headers, follow_redirects=True).data
|
||||
if 'SecurityAW' in data:
|
||||
if 'AWCookieVerify' in data:
|
||||
get_cookie(data)
|
||||
data = get_data(item)
|
||||
return data
|
||||
@@ -37,8 +37,8 @@ def order():
|
||||
@support.menu
|
||||
def mainlist(item):
|
||||
anime=['/filter?sort=',
|
||||
('ITA',['/filter?dub=1&sort=', 'menu', 'dub=1']),
|
||||
('SUB-ITA',['/filter?dub=0&sort=', 'menu', 'dub=0']),
|
||||
('ITA',['/filter?dub=1&sort=', 'menu', '1']),
|
||||
('SUB-ITA',['/filter?dub=0&sort=', 'menu', '0']),
|
||||
('In Corso', ['/ongoing', 'peliculas','noorder']),
|
||||
('Ultimi Episodi', ['/updated', 'peliculas', 'updated']),
|
||||
('Nuove Aggiunte',['/newest', 'peliculas','noorder' ]),
|
||||
@@ -50,7 +50,6 @@ def mainlist(item):
|
||||
def genres(item):
|
||||
action = 'peliculas'
|
||||
data = get_data(item)
|
||||
|
||||
patronBlock = r'dropdown[^>]*>\s*Generi\s*<span.[^>]+>(?P<block>.*?)</ul>'
|
||||
patronMenu = r'<input.*?name="(?P<name>[^"]+)" value="(?P<value>[^"]+)"\s*>[^>]+>(?P<title>[^<]+)</label>'
|
||||
|
||||
@@ -76,10 +75,9 @@ def menu(item):
|
||||
def submenu(item):
|
||||
action = 'peliculas'
|
||||
data = item.other
|
||||
# debug=True
|
||||
patronMenu = r'<input.*?name="(?P<name>[^"]+)" value="(?P<value>[^"]+)"\s*>[^>]+>(?P<title>[^<]+)<\/label>'
|
||||
def itemHook(item):
|
||||
item.url = '{}/filter?{}={}&{}{}'.format(host, item.name, item.value, item.args, ('&sort=' if item.name != 'sort' else ''))
|
||||
item.url = host + '/filter?' + item.name + '=' + item.value + '&dub=' + item.args + ('&sort=' if item.name != 'sort' else '')
|
||||
return item
|
||||
return locals()
|
||||
|
||||
@@ -87,10 +85,9 @@ def submenu(item):
|
||||
def newest(categoria):
|
||||
support.info(categoria)
|
||||
item = support.Item()
|
||||
lang = config.get_setting('lang', channel=item.channel)
|
||||
try:
|
||||
if categoria == "anime":
|
||||
item.url = host
|
||||
item.url = host + '/updated'
|
||||
item.args = "updated"
|
||||
return peliculas(item)
|
||||
# Continua la ricerca in caso di errore
|
||||
@@ -101,13 +98,13 @@ def newest(categoria):
|
||||
return []
|
||||
|
||||
|
||||
def search(item, text):
|
||||
support.info(text)
|
||||
def search(item, texto):
|
||||
support.info(texto)
|
||||
if item.search:
|
||||
item.url = '{}/filter?{}&keyword={}&sort='.format(host, item.args, text)
|
||||
item.url = host + '/filter?dub=' + item.args + '&keyword=' + texto + '&sort='
|
||||
else:
|
||||
lang = ['?', '?dub=1&', '?dub=0&'][config.get_setting('lang', channel=item.channel)]
|
||||
item.url = '{}/filter{}&keyword={}&sort='.format(host, lang, text)
|
||||
item.args = 'noorder'
|
||||
item.url = host + '/search?keyword=' + texto
|
||||
item.contentType = 'tvshow'
|
||||
try:
|
||||
return peliculas(item)
|
||||
@@ -121,8 +118,8 @@ def search(item, text):
|
||||
|
||||
@support.scrape
|
||||
def peliculas(item):
|
||||
data = get_data(item)
|
||||
anime = True
|
||||
# debug = True
|
||||
if item.args not in ['noorder', 'updated'] and not item.url[-1].isdigit(): item.url += order() # usa l'ordinamento di configura canale
|
||||
data = get_data(item)
|
||||
|
||||
@@ -188,9 +185,7 @@ def findvideos(item):
|
||||
else:
|
||||
dataJson = support.match(host + '/api/episode/info?id=' + epID + '&alt=0', headers=headers).data
|
||||
json = jsontools.load(dataJson)
|
||||
|
||||
title = support.match(json['grabber'], patron=r'server\d+.([^.]+)', string=True).match
|
||||
if title: itemlist.append(item.clone(action="play", title=title, url=json['grabber'].split('=')[-1], server='directo'))
|
||||
else: urls.append(json['grabber'])
|
||||
# support.info(urls)
|
||||
return support.server(item, urls, itemlist)
|
||||
|
||||
4
channels/aniplay.json
Executable file → Normal file
4
channels/aniplay.json
Executable file → Normal file
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"id": "aniplay",
|
||||
"name": "AniPlay",
|
||||
"active": false,
|
||||
"active": true,
|
||||
"language": ["ita", "sub-ita"],
|
||||
"thumbnail": "aniplay.png",
|
||||
"banner": "aniplay.png",
|
||||
@@ -34,4 +34,4 @@
|
||||
"lvalues": ["10", "20", "30", "40", "50", "60", "80", "90"]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
70
channels/aniplay.py
Executable file → Normal file
70
channels/aniplay.py
Executable file → Normal file
@@ -1,5 +1,5 @@
|
||||
from platformcode import config, logger, autorenumber
|
||||
from core import httptools, scrapertools, support, tmdb, jsontools
|
||||
from core import httptools, scrapertools, support, tmdb
|
||||
from inspect import stack
|
||||
|
||||
import sys
|
||||
@@ -34,7 +34,6 @@ def submenu_az(item):
|
||||
thumbnail=support.thumb('az')))
|
||||
return itemlist
|
||||
|
||||
|
||||
def submenu_year(item):
|
||||
itemlist = []
|
||||
from datetime import date
|
||||
@@ -47,7 +46,6 @@ def submenu_year(item):
|
||||
thumbnail=support.thumb('year')))
|
||||
return itemlist
|
||||
|
||||
|
||||
def submenu_top(item):
|
||||
itemlist = []
|
||||
links = {'Top del giorno':'daily-top', 'Top della settimana':'weekly-top', 'Top del mese':'monthly-top'}
|
||||
@@ -58,7 +56,6 @@ def submenu_top(item):
|
||||
variable= link))
|
||||
return itemlist
|
||||
|
||||
|
||||
def submenu_season(item):
|
||||
itemlist = []
|
||||
seasons = {'winter':'Inverno', 'spring':'Primavera', 'summer':'Estate', 'fall':'Autunno'}
|
||||
@@ -68,13 +65,12 @@ def submenu_season(item):
|
||||
s = season['season'].split('.')[-1]
|
||||
title = seasons[s]
|
||||
itemlist.append(item.clone(title=title,
|
||||
url = '{}/api/seasonal-view/{}-{}'.format(host, s, item.variable),
|
||||
thumbnail = support.thumb(s),
|
||||
action = 'peliculas',
|
||||
variable=''))
|
||||
url = '{}/api/seasonal-view/{}-{}'.format(host, s, item.variable),
|
||||
thumbnail = support.thumb(s),
|
||||
action = 'peliculas',
|
||||
variable=''))
|
||||
return itemlist
|
||||
|
||||
|
||||
def submenu_top_of(item):
|
||||
itemlist = []
|
||||
url= '{}/api/home/{}'.format(host, item.variable)
|
||||
@@ -87,14 +83,15 @@ def submenu_top_of(item):
|
||||
long_title = support.typo(title, 'bold') + support.typo(lang, '_ [] color kod')
|
||||
|
||||
itemlist.append(item.clone(title=long_title,
|
||||
url = '{}/anime/{}'.format(host, anime['animeId']),
|
||||
video_url = '{}/api/anime/{}'.format(host, anime['animeId']),
|
||||
thumbnail = get_thumbnail(anime, 'animeHorizontalImages'),
|
||||
action = 'episodios',
|
||||
variable=anime['animeId']))
|
||||
id=anime['animeId'],
|
||||
url = '{}/api/anime/{}'.format(host, anime['animeId']),
|
||||
thumbnail = get_thumbnail(anime, 'animeHorizontalImages'),
|
||||
action = 'episodios',
|
||||
variable=anime['animeId']))
|
||||
return itemlist
|
||||
|
||||
|
||||
|
||||
def search(item, texto):
|
||||
support.info(texto)
|
||||
item.url = host + '/api/anime/advanced-search'
|
||||
@@ -139,14 +136,15 @@ def latest_added(item):
|
||||
|
||||
itemlist.append(item.clone(title=long_title,
|
||||
fulltitle=title,
|
||||
url='{}/play/{}'.format(host, episode['id']),
|
||||
animeId = episode['animeId'],
|
||||
id=episode['id'],
|
||||
contentType = 'episode',
|
||||
contentTitle = title,
|
||||
contentSerieName = animeTitle,
|
||||
contentLanguage = lang,
|
||||
quality = quality,
|
||||
contentEpisodeNumber = int(float(episode['episodeNumber'])),
|
||||
video_url = '{}/api/episode/{}'.format(host, episode['id']),
|
||||
animeUrl = '{}/api/anime/{}'.format(host, episode['animeId']),
|
||||
thumbnail = image,
|
||||
fanart = image,
|
||||
action = 'findvideos'))
|
||||
@@ -165,7 +163,6 @@ def peliculas(item):
|
||||
js = httptools.downloadpage('{}?page={}&size={}{}&sort={},{}&sort=id'.format(item.url, page, perpage, item.variable, sort, order)).json
|
||||
|
||||
for it in js:
|
||||
logger.debug(jsontools.dump(js))
|
||||
title, lang = get_lang(it['title'])
|
||||
|
||||
long_title = support.typo(title, 'bold') + support.typo(lang, '_ [] color kod')
|
||||
@@ -177,10 +174,10 @@ def peliculas(item):
|
||||
contentType = 'movie' if it['type'] == 'Movie' else 'tvshow',
|
||||
contentTitle = title,
|
||||
contentSerieName = title if it['type'] == 'Serie' else '',
|
||||
action ='findvideos' if it['type'] == 'Movie' else 'episodios',
|
||||
action ='findvideos' if it['type'] == 'Movie' else 'episodios',# '' if not active else 'findvideos' if it['type'] == 'Movie' else 'episodios',
|
||||
plot = it['storyline'],
|
||||
url = '{}/anime/{}'.format(host, it['id']),
|
||||
video_url = '{}/api/anime/{}'.format(host, it.get('animeId', it.get('id'))),
|
||||
# year = it['startDate'].split('-')[0],
|
||||
url = '{}/api/anime/{}'.format(host, it['id']),
|
||||
thumbnail = get_thumbnail(it),
|
||||
fanart = get_thumbnail(it, 'horizontalImages')))
|
||||
|
||||
@@ -195,10 +192,9 @@ def peliculas(item):
|
||||
def episodios(item):
|
||||
logger.debug()
|
||||
itemlist = []
|
||||
if not item.video_url:
|
||||
item.video_url = item.url.replace('/anime/', '/api/anime/')
|
||||
|
||||
# url = '{}/api/anime/{}'.format(host, item.id)
|
||||
json = httptools.downloadpage(item.video_url, CF=False ).json
|
||||
json = httptools.downloadpage(item.url, CF=False ).json
|
||||
|
||||
if type(json) == list:
|
||||
item.show_renumber = False
|
||||
@@ -212,7 +208,7 @@ def episodios(item):
|
||||
title = it['name']
|
||||
|
||||
itemlist.append(item.clone(title = title,
|
||||
video_url = '{}/api/anime/{}/season/{}'.format(host, it['animeId'], it['id']),
|
||||
id= '{}/season/{}'.format(it['animeId'], it['id']),
|
||||
contentType = 'season',
|
||||
action = 'list_episodes',
|
||||
plot = json['storyline'],
|
||||
@@ -249,7 +245,8 @@ def list_episodes(item, json=None):
|
||||
itemlist = []
|
||||
|
||||
if not json:
|
||||
json = httptools.downloadpage(item.video_url, CF=False ).json
|
||||
url = '{}/api/anime/{}'.format(host, item.id)
|
||||
json = httptools.downloadpage(url, CF=False ).json
|
||||
|
||||
episodes = json['episodes'] if 'episodes' in json else json
|
||||
episodes.sort(key=lambda ep: int(ep['episodeNumber'].split('.')[0]))
|
||||
@@ -266,8 +263,8 @@ def list_episodes(item, json=None):
|
||||
image = get_thumbnail(it, 'episodeImages')
|
||||
|
||||
itemlist.append(item.clone(title = title,
|
||||
url= '{}/play/{}'.format(host, it['id']),
|
||||
video_url= '{}/api/episode/{}'.format(host, it['id']),
|
||||
id= it['id'],
|
||||
url= 'api/episode/{}'.format(it['id']),
|
||||
contentType = 'episode',
|
||||
contentEpisodeNumber = int(it['episodeNumber'].split('.')[0]),
|
||||
contentSeason = item.contentSeason if item.contentSeason else '',
|
||||
@@ -286,18 +283,21 @@ def list_episodes(item, json=None):
|
||||
def findvideos(item):
|
||||
logger.debug()
|
||||
|
||||
res = httptools.downloadpage(item.video_url, CF=False ).json
|
||||
url = '{}/api/{}/{}'.format(host, 'episode' if item.contentType == 'episode' else 'anime', item.id)
|
||||
|
||||
if res.get('episodes', []):
|
||||
res = httptools.downloadpage('{}/api/episode/{}'.format(host, res['episodes'][0]['id'])).json
|
||||
json = httptools.downloadpage(url, CF=False ).json
|
||||
|
||||
item.url = res['videoUrl']
|
||||
item.server = 'directo'
|
||||
if json.get('episodes', []):
|
||||
json = httptools.downloadpage('{}/api/episode/{}'.format(host, json['episodes'][0]['id'])).json
|
||||
# logger.debug(json)
|
||||
|
||||
if '.m3u' in item.url:
|
||||
item.manifest = 'hls'
|
||||
videourl = json['videoUrl']
|
||||
|
||||
return support.server(item, itemlist=[item])
|
||||
itemlist = [item.clone(title=config.get_localized_string(30137),
|
||||
url=videourl,
|
||||
server='directo')]
|
||||
|
||||
return support.server(item, itemlist=itemlist)
|
||||
|
||||
|
||||
def get_thumbnail(data, prop = 'verticalImages', key = 'full'):
|
||||
|
||||
2
channels/casacinema.json
Executable file → Normal file
2
channels/casacinema.json
Executable file → Normal file
@@ -2,7 +2,7 @@
|
||||
"id": "casacinema",
|
||||
"name": "Casacinema",
|
||||
"language": ["ita", "sub-ita"],
|
||||
"active": false,
|
||||
"active": true,
|
||||
"thumbnail": "casacinema.png",
|
||||
"banner": "casacinema.png",
|
||||
"categories": ["tvshow", "movie","vos"],
|
||||
|
||||
33
channels/casacinema.py
Executable file → Normal file
33
channels/casacinema.py
Executable file → Normal file
@@ -36,20 +36,20 @@ def genres(item):
|
||||
|
||||
def check(item):
|
||||
item.data = support.match(item).data
|
||||
if 'episodi e stagioni' in item.data.lower():
|
||||
support.info('select = ### è una serie ###')
|
||||
item.contentType = 'tvshow'
|
||||
return episodios(item)
|
||||
else:
|
||||
if 'continua con il video' in item.data.lower():
|
||||
support.info('select = ### è un film ###')
|
||||
item.contentType = 'movie'
|
||||
return findvideos(item)
|
||||
else:
|
||||
support.info('select = ### è una serie ###')
|
||||
item.contentType = 'tvshow'
|
||||
return episodios(item)
|
||||
|
||||
|
||||
def search(item, text):
|
||||
support.info(text)
|
||||
text = text.replace(' ', '+')
|
||||
item.url = host + '/?a=b&s=' + text
|
||||
item.url = host + '/?s=' + text
|
||||
item.args = 'search'
|
||||
try:
|
||||
return peliculas(item)
|
||||
@@ -93,6 +93,7 @@ def newest(categoria):
|
||||
|
||||
@support.scrape
|
||||
def peliculas(item):
|
||||
# debug = True
|
||||
if item.contentType == 'movie':
|
||||
action = 'findvideos'
|
||||
elif item.contentType == 'tvshow':
|
||||
@@ -104,10 +105,11 @@ def peliculas(item):
|
||||
if item.args == 'newest':
|
||||
patron = r'<li><a href="(?P<url>[^"]+)"[^=]+="(?P<thumb>[^"]+)"><div>\s*?<div[^>]+>(?P<title>[^\(\[<]+)(?:\[(?P<quality1>HD)\])?[ ]?(?:\(|\[)?(?P<lang>[sS]ub-[iI][tT][aA])?(?:\)|\])?[ ]?(?:\[(?P<quality>.+?)\])?[ ]?(?:\((?P<year>\d+)\))?<(?:[^>]+>.+?(?:title="Nuovi episodi">(?P<episode>\d+x\d+)[ ]?(?P<lang2>Sub-Ita)?|title="IMDb">(?P<rating>[^<]+)))?'
|
||||
else:
|
||||
# patron = r'<li><a href="(?P<url>[^"]+)"[^=]+="(?P<thumb>[^"]+)"><div>\s*?<div[^>]+>(?P<title>[^\(\[<]+)(?:\[(?P<quality1>HD)\])?\s?(?:[\(\[])?(?P<lang>[sS]ub-[iI][tT][aA])?(?:[\)\]])?\s?(?:\[(?P<quality>.+?)\])?\s?(?:\((?P<year>\d+)\))?<'
|
||||
patron = r'<li><a href="(?P<url>[^"]+)"[^=]+="(?P<thumb>[^"]+)"><div>\s*?<div[^>]+>(?P<title>[^\(\[<]+)(?P<title2>\([\D*]+\))?(?:\[(?P<quality1>HD)\])?\s?(?:[\(\[])?(?P<lang>[sS]ub-[iI][tT][aA])?(?:[\)\]])?\s?(?:\[(?P<quality>.+?)\])?\s?(?:\((?P<year>\d+)\))?(?:\(\D{2}\s\d{4}\))?<'
|
||||
|
||||
patronNext = r'<a href="([^"]+)"\s*>Pagina'
|
||||
|
||||
# debug = True
|
||||
|
||||
def itemHook(item):
|
||||
if item.quality1:
|
||||
@@ -118,7 +120,8 @@ def peliculas(item):
|
||||
item.title += support.typo(item.lang2, '_ [] color kod')
|
||||
if item.args == 'novita':
|
||||
item.title = item.title
|
||||
|
||||
# if 'wp-content' in item.thumbnail and not item.infoLabels['year']:
|
||||
# item.infoLabels['year'] = item.thumbnail.split('/')[5]
|
||||
return item
|
||||
return locals()
|
||||
|
||||
@@ -130,8 +133,11 @@ def episodios(item):
|
||||
action = 'findvideos'
|
||||
item.contentType = 'tvshow'
|
||||
blacklist = ['']
|
||||
# debug = True
|
||||
patron = r'"season-no">(?P<season>\d+)x(?P<episode>\d+)(?:[^>]+>){5}\s*(?P<title>[^<]+)(?P<data>.*?)</table>'
|
||||
# patron = r'(?P<episode>\d+(?:×|×)?\d+\-\d+|\d+(?:×|×)\d+)[;]?(?:(?P<title>[^<]+)<(?P<data>.*?)|(\2[ ])(?:<(\3.*?)))(?:<br />|</p>)'
|
||||
patronBlock = r'<span>(?:.+?Stagione*.+?(?P<lang>[Ii][Tt][Aa]|[Ss][Uu][Bb][\-]?[iI][tT][aA]))?.*?</span>.*?class="content(?P<block>.*?)(?:"accordion-item|<script>)'
|
||||
# patronBlock = r'<strong>(?P<block>(?:.+?Stagione*.+?(?P<lang>[Ii][Tt][Aa]|[Ss][Uu][Bb][\-]?[iI][tT][aA]))?(?:.+?|</strong>)(/?:</span>)?</p>.*?</p>)'
|
||||
return locals()
|
||||
|
||||
|
||||
@@ -139,7 +145,10 @@ def findvideos(item):
|
||||
if item.contentType != 'movie':
|
||||
links = support.match(item.data, patron=r'href="([^"]+)"').matches
|
||||
else:
|
||||
matchData = item.data if item.data else support.match(item.url, headers=headers).data
|
||||
links = support.match(matchData, patron=r'data-id="([^"]+)"').matches
|
||||
|
||||
return support.server(item, links)
|
||||
matchData = item.data if item.data else item
|
||||
links = support.match(matchData, patron=r'(?:SRC|href)="([^"]+)"', patronBlock=r'<div class="col-md-10">(.+?)<div class="ads">').matches
|
||||
data = ''
|
||||
for link in links:
|
||||
support.info('URL=',link)
|
||||
data += link + '\n'
|
||||
return support.server(item, data)
|
||||
|
||||
0
channels/cb01anime.json
Executable file → Normal file
0
channels/cb01anime.json
Executable file → Normal file
0
channels/cb01anime.py
Executable file → Normal file
0
channels/cb01anime.py
Executable file → Normal file
0
channels/cineblog01.json
Executable file → Normal file
0
channels/cineblog01.json
Executable file → Normal file
31
channels/cineblog01.py
Executable file → Normal file
31
channels/cineblog01.py
Executable file → Normal file
@@ -2,6 +2,7 @@
|
||||
# ------------------------------------------------------------
|
||||
# Canale per cineblog01
|
||||
# ------------------------------------------------------------
|
||||
import datetime
|
||||
import re
|
||||
|
||||
from core import scrapertools, httptools, servertools, support
|
||||
@@ -23,19 +24,17 @@ headers = [['Referer', host]]
|
||||
def mainlist(item):
|
||||
film = [
|
||||
('HD', ['', 'menu', 'Film HD Streaming']),
|
||||
('Genere', ['', 'menu', 'Film per Genere']),
|
||||
('Generi', ['', 'menu', 'Film per Genere']),
|
||||
('Anni', ['', 'menu', 'Film per Anno']),
|
||||
('Popolari per Genere', ['', 'menu', 'Film Popolari']),
|
||||
('Ultimi Aggiunti', ['/ultimi-100-film-aggiunti/', 'peliculas', 'newest']),
|
||||
('Popolari', ['/category/film-popolari/']),
|
||||
('Italiani', ['/category/nazione/italia/'])
|
||||
# ('Film in Lista', ['/lista-film/', 'peliculas', 'newest'])
|
||||
('Paese', ['', 'menu', 'Film per Paese']),
|
||||
('Ultimi Aggiornati', ['/ultimi-100-film-aggiornati/', 'peliculas', 'newest']),
|
||||
('Ultimi Aggiunti', ['/lista-film-ultimi-100-film-aggiunti/', 'peliculas', 'newest'])
|
||||
]
|
||||
tvshow = ['/serietv/',
|
||||
('Per Lettera', ['/serietv/', 'menu', 'Serie-TV x Lettera']),
|
||||
('Per Genere', ['/serietv/', 'menu', 'Serie-TV x Genere']),
|
||||
('Per anno', ['/serietv/', 'menu', 'Serie-TV x Anno']),
|
||||
('Ultime Aggiunte', ['/serietv/ultime-100-serie-tv-aggiunte/', 'peliculas', 'newest'])
|
||||
('Per Lettera', ['/serietv/', 'menu', 'Serie-Tv per Lettera']),
|
||||
('Per Genere', ['/serietv/', 'menu', 'Serie-Tv per Genere']),
|
||||
('Per anno', ['/serietv/', 'menu', 'Serie-Tv per Anno']),
|
||||
('Ultime Aggiornate', ['/serietv/ultime-100-serie-tv-aggiornate/', 'peliculas', 'newest'])
|
||||
]
|
||||
docu = [('Documentari {bullet bold}', ['/category/documentario/', 'peliculas']),
|
||||
('HD {submenu} {documentari}', ['/category/hd-alta-definizione/documentario-hd/', 'peliculas'])
|
||||
@@ -46,9 +45,9 @@ def mainlist(item):
|
||||
|
||||
@support.scrape
|
||||
def menu(item):
|
||||
# debug = True
|
||||
# debug=True
|
||||
patronBlock = item.args + r'<span.*?><\/span>.*?<ul.*?>(?P<block>.*?)<\/ul>'
|
||||
patronMenu = r'href="?(?P<url>[^">]+)"?[^>]+>(?P<title>[^<»]+)'
|
||||
patronMenu = r'href="?(?P<url>[^">]+)"?>(?P<title>[^<»]+)'
|
||||
action = 'peliculas'
|
||||
|
||||
return locals()
|
||||
@@ -64,7 +63,7 @@ def newest(categoria):
|
||||
item.url = host + '/serietv/' # aggiornamento-quotidiano-serie-tv/'
|
||||
else:
|
||||
item.contentType = 'movie'
|
||||
item.url = host + '/ultimi-100-film-aggiunti/'
|
||||
item.url = host + '/lista-film-ultimi-100-film-aggiunti/'
|
||||
item.args = "newest"
|
||||
return peliculas(item)
|
||||
# Continua la ricerca in caso di errore
|
||||
@@ -93,7 +92,7 @@ def search(item, text):
|
||||
|
||||
@support.scrape
|
||||
def peliculas(item):
|
||||
#debug = True
|
||||
# debug = True
|
||||
# esclusione degli articoli 'di servizio'
|
||||
# curYear = datetime.date.today().year
|
||||
# blacklist = ['BENVENUTI', 'Richieste Serie TV', 'CB01.UNO ▶ TROVA L’INDIRIZZO UFFICIALE ',
|
||||
@@ -113,7 +112,7 @@ def peliculas(item):
|
||||
action = 'episodios'
|
||||
|
||||
elif '/serietv/' not in item.url:
|
||||
patron = r'(?<!sticky )hentry.*?<div class="card-image">\s*<a[^>]+>\s*<img src="(?P<thumb>[^" ]+)" alt[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+><a href="?(?P<url>[^" >]+)(?:\/|"|\s+)>(?P<title>[^<[(]+)(?:\[(?P<quality>[a-zA-Z]+(?:[/]?3D)?)\]\s*)?(?:\[(?P<lang>Sub-ITA|ITA)\]\s*)?(?:\[(?P<quality2>[a-zA-Z/]+)\]\s*)? (?:\((?P<year>[0-9]{4})\))?[^>]+>[^>]+>[^>]+>[^>]+>(?P<genre>[^<>&âÃÂÖ]+)(?:[^ ]+\s*DURATA\s*(?P<duration>[0-9]+)[^>]+>[^>]+>[^>]+>(?P<plot>[^<>]+))?'
|
||||
patron = r'(?<!sticky )hentry.*?<div class="card-image">\s*<a[^>]+>\s*<img src="(?P<thumb>[^" ]+)" alt[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+><a href="?(?P<url>[^" >]+)(?:\/|"|\s+)>(?P<title>[^<[(]+)(?:\[(?P<quality>[a-zA-Z]+(?:[/]?3D)?)\]\s*)?(?:\[(?P<lang>Sub-ITA|ITA)\]\s*)?(?:\[(?P<quality2>[a-zA-Z/]+)\]\s*)? (?:\((?P<year>[0-9]{4})\))?[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>(?P<genre>[^<>&âÃÂÖ]+)(?:[^ ]+\s*DURATA\s*(?P<duration>[0-9]+)[^>]+>[^>]+>[^>]+>(?P<plot>[^<>]+))?'
|
||||
action = 'findvideos'
|
||||
|
||||
else:
|
||||
@@ -145,7 +144,7 @@ def episodios(item):
|
||||
addVideolibrary = False
|
||||
downloadEnabled = False
|
||||
|
||||
patron = r'<tr><td>(?P<title>[^<]+)<td><span [^>].+?><a [^>]+href="(?P<url>[^"]+)[^>]+>'
|
||||
patron = r'<td>(?P<title>[^<]+)<td><a [^>]+href="(?P<url>[^"]+)[^>]+>'
|
||||
sceneTitle = True
|
||||
# debug = True
|
||||
|
||||
|
||||
2
channels/cinemalibero.json
Executable file → Normal file
2
channels/cinemalibero.json
Executable file → Normal file
@@ -2,7 +2,7 @@
|
||||
"id": "cinemalibero",
|
||||
"name": "Cinemalibero",
|
||||
"language": ["ita"],
|
||||
"active": false,
|
||||
"active": true,
|
||||
"thumbnail": "cinemalibero.png",
|
||||
"banner": "cinemalibero.png",
|
||||
"categories": ["movie","tvshow","anime"],
|
||||
|
||||
74
channels/cinemalibero.py
Executable file → Normal file
74
channels/cinemalibero.py
Executable file → Normal file
@@ -97,11 +97,10 @@ def peliculas(item):
|
||||
@support.scrape
|
||||
def episodios(item):
|
||||
data = item.data
|
||||
# debug=True
|
||||
|
||||
if item.args == 'anime':
|
||||
logger.debug("Anime :", item)
|
||||
patron = r'<a target=(?P<url>[^>]+>(?P<title>Episodio\s(?P<episode>\d+))(?::)?(?:(?P<title2>[^<]+))?.*?(?:<br|</p))|(?P<data>.+)'
|
||||
patron = r'<a target=(?P<url>[^>]+>(?P<title>Episodio\s(?P<episode>\d+))(?::)?(?:(?P<title2>[^<]+))?.*?(?:<br|</p))'
|
||||
patronBlock = r'(?:Stagione (?P<season>\d+))?(?:</span><br />|</span></p>|strong></p>)(?P<block>.*?)(?:<div style="margin-left|<span class="txt_dow">)'
|
||||
item.contentType = 'tvshow'
|
||||
elif item.args == 'sport':
|
||||
@@ -111,6 +110,7 @@ def episodios(item):
|
||||
item.contentType = 'tvshow'
|
||||
elif item.args == 'serie' or item.contentType == 'tvshow':
|
||||
logger.debug("Serie :", item)
|
||||
# debug=True
|
||||
patron = r'(?:/>|<p>)\s*(?:(?P<episode>\d+(?:x|×|×)\d+|Puntata \d+)(?:-(?P<episode2>\d+))?[;]?[ ]?(?P<title>[^<–-]+))?(?P<data>.*?)(?:<br|</p)'
|
||||
patronBlock = r'Stagione\s(?:[Uu]nica)?(?:(?P<lang>iTA|ITA|Sub-ITA|Sub-iTA))?.*?</strong>(?P<block>.+?)(?:strong>|<div class="at-below)'
|
||||
item.contentType = 'tvshow'
|
||||
@@ -130,38 +130,28 @@ def episodios(item):
|
||||
for it in itl:
|
||||
ep = scrapertools.find_single_match(it.title, r'(\d+x\d+)')
|
||||
if not ep and 'http' in it.data: # stagione intera
|
||||
# from lib import unshortenit
|
||||
# data = unshortenit.findlinks(it.data)
|
||||
episodes = {}
|
||||
|
||||
from lib import unshortenit
|
||||
data = unshortenit.findlinks(it.data)
|
||||
def get_ep(s):
|
||||
srv_mod = __import__('servers.%s' % s.server, None, None, ["servers.%s" % s.server])
|
||||
if hasattr(srv_mod, 'get_filename'):
|
||||
title = srv_mod.get_filename(s.url)
|
||||
if item.args == 'anime':
|
||||
ep = title
|
||||
else:
|
||||
ep = scrapertools.get_season_and_episode(title)
|
||||
ep = scrapertools.get_season_and_episode(title)
|
||||
if ep:
|
||||
if ep not in episodes:
|
||||
episodes[ep] = []
|
||||
episodes[ep].append(s)
|
||||
|
||||
servers = support.server(item, it.data, CheckLinks=False, Download=False, Videolibrary=False)
|
||||
# for s in servers:
|
||||
# get_ep(s)
|
||||
servers = support.server(item, data, CheckLinks=False, Download=False, Videolibrary=False)
|
||||
episodes = {}
|
||||
for s in servers:
|
||||
get_ep(s)
|
||||
# ottengo l'episodio dal nome del file
|
||||
with futures.ThreadPoolExecutor() as executor:
|
||||
for s in servers:
|
||||
executor.submit(get_ep, s)
|
||||
# with futures.ThreadPoolExecutor() as executor:
|
||||
# for s in servers:
|
||||
# executor.submit(get_ep, s)
|
||||
# logger.debug(it.contentLanguage)
|
||||
if item.args != 'anime':
|
||||
for ep in episodes:
|
||||
ret.append(it.clone(title=typo(ep, 'bold') + typo(it.contentLanguage, '_ [] color kod bold'),
|
||||
servers=[srv.tourl() for srv in episodes[ep]], contentSeason=int(ep.split('x')[0]), contentEpisodeNumber=int(ep.split('x')[1])))
|
||||
else:
|
||||
ret.extend([it.clone(title=typo(ep, 'bold') + typo(it.contentLanguage, '_ [] color kod bold'),
|
||||
servers=[srv.tourl() for srv in episodes[ep]]) for ep in episodes])
|
||||
ret.extend([it.clone(title=typo(ep, 'bold')+typo(it.contentLanguage, '_ [] color kod bold'), contentSeason=int(ep.split('x')[0]), contentEpisodeNumber=int(ep.split('x')[1]), servers=[srv.tourl() for srv in episodes[ep]]) for ep in episodes])
|
||||
elif ep:
|
||||
ret.append(it)
|
||||
return sorted(ret, key=lambda i: i.title)
|
||||
@@ -216,15 +206,16 @@ def newest(categoria):
|
||||
|
||||
|
||||
def check(item):
|
||||
logger.debug()
|
||||
data = support.match(item.url, headers=headers).data
|
||||
|
||||
# support.dbg()
|
||||
if data:
|
||||
ck = str(support.match(data, patronBlock=r'Genere:(.*?)</span>', patron=r'tag">([^<]+)').matches).lower()
|
||||
|
||||
if 'serie tv' in ck or 'anime' in ck or 'wrestling wwe' in ck :# in ['serie tv', 'wrestling wwe', 'anime']:
|
||||
if 'serie tv' in ck or 'anime' in ck:# in ['serie tv', 'wrestling wwe', 'anime']:
|
||||
if 'anime' in ck:
|
||||
item.args = 'anime'
|
||||
elif 'sport' in ck or 'wrestling' in ck:
|
||||
elif 'sport' in ck:
|
||||
item.args = 'sport'
|
||||
else:
|
||||
item.args = 'serie'
|
||||
@@ -258,25 +249,26 @@ def findvideos(item):
|
||||
return support.server(item, itemlist=[Item().fromurl(s) for s in item.servers])
|
||||
if not item.data:
|
||||
item.data = httptools.downloadpage(item.url)
|
||||
data = scrapertools.find_single_match(item.data, '<div class="at-above-post addthis_tool"(.*?)(?:<div class="at-below-post|[dD][oO][wW][nN][lL][oO][aA][dD])')
|
||||
data = scrapertools.find_single_match(item.data, '<div class="at-above-post addthis_tool"(.*?)<div class="at-below-post')
|
||||
if data:
|
||||
item.data = data
|
||||
|
||||
servers = []
|
||||
# if item.args == 'anime':
|
||||
# if item.urls: # this is a episode
|
||||
# return support.server(item, itemlist=[Item(url=support.unshortenit.FileCrypt().unshorten(u)) for u in item.urls])
|
||||
# itemlist = []
|
||||
# episodes = {}
|
||||
# for uri in support.unshortenit.FileCrypt().find(item.data):
|
||||
# for ep in support.unshortenit.FileCrypt(uri).list_files():
|
||||
# ep = ('.'.join(ep[0].split('.')[:-1]), ep[1]) # remove extension
|
||||
# if not ep[0] in episodes:
|
||||
# episodes[ep[0]] = []
|
||||
# episodes[ep[0]].append(ep[1])
|
||||
# for ep in episodes.keys():
|
||||
# itemlist.append(item.clone(title=ep, urls=episodes[ep], action='findvideos', data=''))
|
||||
# return itemlist
|
||||
if item.args == 'anime':
|
||||
if item.urls: # this is a episode
|
||||
return support.server(item, itemlist=[Item(url=support.unshortenit.FileCrypt().unshorten(u)) for u in item.urls])
|
||||
itemlist = []
|
||||
episodes = {}
|
||||
# support.dbg()
|
||||
for uri in support.unshortenit.FileCrypt().find(item.data):
|
||||
for ep in support.unshortenit.FileCrypt(uri).list_files():
|
||||
ep = ('.'.join(ep[0].split('.')[:-1]), ep[1]) # remove extension
|
||||
if not ep[0] in episodes:
|
||||
episodes[ep[0]] = []
|
||||
episodes[ep[0]].append(ep[1])
|
||||
for ep in episodes.keys():
|
||||
itemlist.append(item.clone(title=ep, urls=episodes[ep], action='findvideos', data=''))
|
||||
return itemlist
|
||||
total_servers = support.server(item, data=item.data)
|
||||
|
||||
if item.contentType == 'episode' and len(set([srv.server for srv in total_servers])) < len([srv.server for srv in total_servers]):
|
||||
|
||||
0
channels/cinetecadibologna.json
Executable file → Normal file
0
channels/cinetecadibologna.json
Executable file → Normal file
0
channels/cinetecadibologna.py
Executable file → Normal file
0
channels/cinetecadibologna.py
Executable file → Normal file
@@ -1,11 +0,0 @@
|
||||
{
|
||||
"id": "dinostreaming",
|
||||
"name": "DinoStreaming",
|
||||
"language": ["ita"],
|
||||
"active": true,
|
||||
"thumbnail": "dinostreaming.png",
|
||||
"banner": "dinostreaming.png",
|
||||
"categories": ["movie"],
|
||||
"settings": [],
|
||||
"not_active": ["include_in_newest"]
|
||||
}
|
||||
@@ -1,77 +0,0 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# ------------------------------------------------------------
|
||||
# Canale per Dinostreaming
|
||||
# by ilmich
|
||||
# ------------------------------------------------------------
|
||||
|
||||
from core import httptools, support
|
||||
from core.item import Item
|
||||
from platformcode import logger
|
||||
|
||||
host = support.config.get_channel_url()
|
||||
headers = [['Referer', host]]
|
||||
|
||||
@support.menu
|
||||
def mainlist(item):
|
||||
film = [('Film al cinema',['/film-category/al-cinema/', 'peliculas']),
|
||||
('Generi',['', 'genres']),
|
||||
]
|
||||
search = ''
|
||||
return locals()
|
||||
|
||||
@support.scrape
|
||||
def genres(item):
|
||||
action = 'peliculas'
|
||||
blacklist = ['Seguici su Telegram',]
|
||||
patronMenu = r'<li class="elementor-icon-list-item">.*?href="(?P<url>.*?)".*?text">(?P<title>.*?)</span>'
|
||||
|
||||
return locals()
|
||||
|
||||
@support.scrape
|
||||
def peliculas(item):
|
||||
if not item.args == 'search': # pagination not works
|
||||
if not item.nextpage:
|
||||
item.page = 1
|
||||
else:
|
||||
item.page = item.nextpage
|
||||
|
||||
if not item.parent_url:
|
||||
item.parent_url = item.url
|
||||
|
||||
item.nextpage = item.page + 1
|
||||
nextPageUrl = "{}/page/{}".format(item.parent_url, item.nextpage)
|
||||
|
||||
resp = httptools.downloadpage(nextPageUrl, only_headers = True)
|
||||
if (resp.code > 399): # no more elements
|
||||
nextPageUrl = ''
|
||||
|
||||
patron = r'<div data-elementor-type="loop-item".*?<a.*?url="(?P<thumb>[^"]+).*?<a href=\"(?P<url>[^"]+)\">(?P<title>.*?)</a>.*?<span class="elementor-heading-title elementor-size-default">(?P<year>.*?)</span>'
|
||||
|
||||
def itemlistHook(itemlist):
|
||||
return itemlist[:-1:]
|
||||
return locals()
|
||||
|
||||
def search(item, text):
|
||||
item.url = "{}/?{}".format(host, support.urlencode({'s': text}))
|
||||
item.args = 'search'
|
||||
|
||||
try:
|
||||
return peliculas(item)
|
||||
|
||||
except:
|
||||
import sys
|
||||
for line in sys.exc_info():
|
||||
logger.error("search except: %s" % line)
|
||||
return []
|
||||
|
||||
def findvideos(item):
|
||||
support.info()
|
||||
data = httptools.downloadpage(item.url).data
|
||||
video_url = support.match(data, patron=r'<a href="([^"]+)" rel="nofollow" title="Guarda il film in streaming">' ).match
|
||||
if (video_url == ''):
|
||||
return []
|
||||
|
||||
item.url = video_url
|
||||
itemlist = support.server(item)
|
||||
return itemlist
|
||||
|
||||
0
channels/discoveryplus.json
Executable file → Normal file
0
channels/discoveryplus.json
Executable file → Normal file
77
channels/discoveryplus.py
Executable file → Normal file
77
channels/discoveryplus.py
Executable file → Normal file
@@ -6,7 +6,7 @@ import functools
|
||||
|
||||
import requests, uuid
|
||||
from core import jsontools, support, httptools
|
||||
from platformcode import logger, config
|
||||
from platformcode import logger
|
||||
|
||||
|
||||
typo = support.typo
|
||||
@@ -18,12 +18,11 @@ deviceId = uuid.uuid4().hex
|
||||
# domain = 'https://eu1-prod-direct.discoveryplus.com'
|
||||
domain = 'https://' + session.get("https://prod-realmservice.mercury.dnitv.com/realm-config/www.discoveryplus.com%2Fit%2Fepg").json()["domain"]
|
||||
token = session.get('{}/token?deviceId={}&realm=dplay&shortlived=true'.format(domain, deviceId)).json()['data']['attributes']['token']
|
||||
session.headers = {'User-Agent': httptools.get_user_agent(), #'Mozilla/50.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Firefox/45.0',
|
||||
session.headers = {'User-Agent': 'Mozilla/50.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Firefox/45.0',
|
||||
'Referer': host,
|
||||
'Origin': host,
|
||||
'Cookie': 'st={}'.format(token),
|
||||
'content-type': 'application/json',
|
||||
'x-disco-client': 'WEB:UNKNOWN:dplus_us:2.46.0',
|
||||
'x-disco-params': 'realm=dplay,siteLookupKey=dplus_it'}
|
||||
|
||||
@support.menu
|
||||
@@ -55,8 +54,7 @@ def live(item):
|
||||
logger.debug()
|
||||
|
||||
itemlist =[]
|
||||
# data = session.get(domain + '/cms/routes/epg?include=default').json()['included']
|
||||
data = session.get(domain + '/cms/routes/home?include=default&decorators=playbackAllowed').json()['included']
|
||||
data = session.get(domain + '/cms/routes/epg?include=default').json()['included']
|
||||
|
||||
for key in data:
|
||||
|
||||
@@ -168,7 +166,7 @@ def seasons(item):
|
||||
data = session.get('{}/cms/routes/show/{}?include=default'.format(domain, item.programid)).json()['included']
|
||||
|
||||
for key in data:
|
||||
if key['type'] == 'collection' and 'filters' in key['attributes']['component']:
|
||||
if key['type'] == 'collection':
|
||||
for option in key['attributes']['component']['filters'][0]['options']:
|
||||
itemlist.append(item.clone(title="Stagione {}".format(option['value']),
|
||||
season=int(option['value']),
|
||||
@@ -179,15 +177,6 @@ def seasons(item):
|
||||
action='episodios'))
|
||||
break
|
||||
|
||||
if key['type'] == 'collection' and 'title' in key['attributes']:
|
||||
itemlist.append(
|
||||
item.clone(title=typo(key['attributes']['title'],'bold'),
|
||||
plot=key['attributes'].get('description',''),
|
||||
programid=key['attributes']['alias'],
|
||||
id=key['id'],
|
||||
action='episodios',
|
||||
contentType='season'))
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
@@ -200,21 +189,13 @@ def episodios(item):
|
||||
|
||||
for key in data:
|
||||
if key['type'] == 'video' and 'Free' in str(key.get('relationships',{}).get('contentPackages',{}).get('data',[])):
|
||||
if item.season:
|
||||
itemlist.append(item.clone(title = "{}x{:02d} - {}".format(item.season, key['attributes']['episodeNumber'], key['attributes']['name']),
|
||||
itemlist.append(item.clone(title = "{}x{:02d} - {}".format(item.season, key['attributes']['episodeNumber'], key['attributes']['name']),
|
||||
plot = key['attributes']['description'],
|
||||
episode = key['attributes']['episodeNumber'],
|
||||
contentType = 'episode',
|
||||
action = 'findvideos',
|
||||
thumbnail = images[key['relationships']['images']['data'][0]['id']],
|
||||
id=key['id']))
|
||||
else:
|
||||
itemlist.append(item.clone(title = key['attributes']['name'],
|
||||
plot = key['attributes']['longDescription'],
|
||||
contentType = 'episode',
|
||||
action = 'findvideos',
|
||||
thumbnail = images[key['relationships']['images']['data'][0]['id']],
|
||||
id=key['id']))
|
||||
|
||||
itemlist.sort(key=lambda it: it.episode)
|
||||
|
||||
@@ -229,52 +210,16 @@ def findvideos(item):
|
||||
logger.debug()
|
||||
|
||||
content = 'video' if item.contentType == 'episode' else 'channel'
|
||||
|
||||
post = {content + 'Id': item.id,
|
||||
'deviceInfo': {
|
||||
'adBlocker': 'true',
|
||||
'drmSupported': 'true',
|
||||
'hwDecodingCapabilities': [],
|
||||
'screen':{
|
||||
'width':1920,
|
||||
'height':1080
|
||||
},
|
||||
'player':{
|
||||
'width':1920,
|
||||
'height':1080
|
||||
}
|
||||
},
|
||||
'wisteriaProperties':{
|
||||
'advertiser': {
|
||||
'firstPlay': 0,
|
||||
'fwIsLat': 0
|
||||
},
|
||||
'device':{
|
||||
'browser':{
|
||||
'name': 'chrome',
|
||||
'version': config.get_setting("chrome_ua_version")
|
||||
},
|
||||
'type': 'desktop'
|
||||
},
|
||||
'platform': 'desktop',
|
||||
'product': 'dplus_emea',
|
||||
'sessionId': deviceId,
|
||||
'streamProvider': {
|
||||
'suspendBeaconing': 0,
|
||||
'hlsVersion': 6,
|
||||
'pingConfig': 1
|
||||
}
|
||||
}
|
||||
}
|
||||
post = {content + 'Id': item.id, 'deviceInfo': {'adBlocker': False,'drmSupported': True}}
|
||||
|
||||
data = session.post('{}/playback/v3/{}PlaybackInfo'.format(domain, content), json=post).json().get('data',{}).get('attributes',{})
|
||||
if data.get('streaming', [{}])[0].get('protection', {}).get('drmEnabled',False):
|
||||
item.url = data['streaming'][0]['url']
|
||||
|
||||
if data.get('protection', {}).get('drmEnabled',False):
|
||||
item.url = data['streaming']['dash']['url']
|
||||
item.drm = 'com.widevine.alpha'
|
||||
item.license ="{}|PreAuthorization={}|R{{SSM}}|".format(data['streaming'][0]['protection']['schemes']['widevine']['licenseUrl'],
|
||||
data['streaming'][0]['protection']['drmToken'])
|
||||
item.license ="{}|PreAuthorization={}|R{{SSM}}|".format(data['protection']['schemes']['widevine']['licenseUrl'], data['protection']['drmToken'])
|
||||
else:
|
||||
item.url = data['streaming'][0]['url']
|
||||
item.manifest = 'hls'
|
||||
|
||||
return support.server(item, itemlist=[item], Download=False, Videolibrary=False)
|
||||
return support.server(item, itemlist=[item], Download=False, Videolibrary=False)
|
||||
0
channels/dreamsub.json
Executable file → Normal file
0
channels/dreamsub.json
Executable file → Normal file
0
channels/dreamsub.py
Executable file → Normal file
0
channels/dreamsub.py
Executable file → Normal file
6
channels/eurostreaming.json
Executable file → Normal file
6
channels/eurostreaming.json
Executable file → Normal file
@@ -1,10 +1,10 @@
|
||||
{
|
||||
"id": "eurostreaming",
|
||||
"name": "Eurostreaming",
|
||||
"active": false,
|
||||
"language": ["ita", "sub-ita"],
|
||||
"active": true,
|
||||
"language": ["ita","sub-ita"],
|
||||
"thumbnail": "eurostreaming.png",
|
||||
"banner": "eurostreaming.png",
|
||||
"categories": ["tvshow", "anime", "vos"],
|
||||
"categories": ["tvshow","anime","vos"],
|
||||
"settings": []
|
||||
}
|
||||
|
||||
7
channels/eurostreaming.py
Executable file → Normal file
7
channels/eurostreaming.py
Executable file → Normal file
@@ -31,7 +31,7 @@ def mainlist(item):
|
||||
def peliculas(item):
|
||||
# debug = True
|
||||
action = 'episodios'
|
||||
|
||||
|
||||
if item.args == 'newest':
|
||||
item.contentType = 'episode'
|
||||
patron = r'<span class="serieTitle" style="font-size:20px">(?P<title>[^<]+) –\s*<a href="(?P<url>[^"]+)"[^>]*>\s+?(?P<episode>\d+[×x]\d+-\d+|\d+[×x]\d+) (?P<title2>[^<\(]+)\s?\(?(?P<lang>SUB ITA)?\)?</a>'
|
||||
@@ -49,9 +49,8 @@ def episodios(item):
|
||||
data = support.match(item, headers=headers).data
|
||||
if 'clicca qui per aprire' in data.lower(): data = support.match(support.match(data, patron=r'"go_to":"([^"]+)"').match.replace('\\',''), headers=headers).data
|
||||
elif 'clicca qui</span>' in data.lower(): data = support.match(support.match(data, patron=r'<h2 style="text-align: center;"><a href="([^"]+)">').match, headers=headers).data
|
||||
|
||||
patronBlock = r'</span>(?P<block>[a-zA-Z\s]+\d+(.+?)?(?:\()?(?P<lang>ITA|SUB ITA)(?:\))?.*?)</div></div>'
|
||||
patron = r'(?P<season>\d+)×(?P<episode>\d+)(</strong>)*(?P<title>.*?)<(?P<other>.*?br/>)'
|
||||
patron = r'(?P<season>\d+)&#\d+;(?P<episode>\d+(?:-\d+)?)\s*(?:</strong>|<em>)?\s*(?P<title>.*?)(?:â|-.+?-|âÂÂ.+?âÂÂ|âÂÂ|em|.)?(?:/em.*?)?(?:<a (?P<other>.*?))?<br />'
|
||||
|
||||
def itemHook(i):
|
||||
i.url = item.url
|
||||
@@ -85,7 +84,7 @@ def newest(categoria):
|
||||
item.contentType = 'tvshow'
|
||||
item.args = 'newest'
|
||||
try:
|
||||
item.url = "%s/aggiornamento-episodi-nuovi/" % host
|
||||
item.url = "%s/aggiornamento-nuovi-episodi/" % host
|
||||
item.action = "peliculas"
|
||||
itemlist = peliculas(item)
|
||||
# Continua la ricerca in caso di errore
|
||||
|
||||
0
channels/eurostreaming_actor.json
Executable file → Normal file
0
channels/eurostreaming_actor.json
Executable file → Normal file
6
channels/eurostreaming_actor.py
Executable file → Normal file
6
channels/eurostreaming_actor.py
Executable file → Normal file
@@ -31,9 +31,9 @@ def peliculas(item):
|
||||
patronNext = r'class="next".*?"(.+?)"'
|
||||
|
||||
else:
|
||||
patron = r'<div class="post-thumb">.*?<img src="(?P<thumb>[^"]+)".*?><a href="(?P<url>[^"]+)"[^>]+>(?P<title>.+?)[\<]'
|
||||
patron = r'<div class="post-thumb">.*?<img src="(?P<thumb>[^"]+)".*?><a href="(?P<url>[^"]+)"[^>]+>(?P<title>.+?)[\<]?[/(](?P<year>.*?)[\)|a]'
|
||||
patronNext = r'next.*?href="(.*?)"'
|
||||
# debug = True
|
||||
|
||||
return locals()
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@ def episodios(item):
|
||||
data = support.match(support.match(data, patron=r'<h2 style="text-align: center;"><a href="([^"]+)">').match, headers=headers).data
|
||||
|
||||
patronBlock = r'tab-content(?P<block>.*?)serie-player'
|
||||
patron = r'data.num..(?P<season>\d+)x(?P<episode>\d+)" data-title="(?P<title>[^"]+).*?data-link="(?P<url>http.*?)</li>'
|
||||
patron = r'data-link="(?P<url>http.*?)".*?data.num..(?P<season>\d+)x(?P<episode>\d+)" data-title="(?P<title>[^"]+)'
|
||||
|
||||
return locals()
|
||||
|
||||
|
||||
2
channels/filmpertutti.json
Executable file → Normal file
2
channels/filmpertutti.json
Executable file → Normal file
@@ -5,6 +5,6 @@
|
||||
"language": ["ita", "sub-ita"],
|
||||
"thumbnail": "filmpertutti.png",
|
||||
"banner": "filmpertutti.png",
|
||||
"categories": ["anime", "tvshow","movie"],
|
||||
"categories": ["tvshow","movie"],
|
||||
"settings": []
|
||||
}
|
||||
|
||||
168
channels/filmpertutti.py
Executable file → Normal file
168
channels/filmpertutti.py
Executable file → Normal file
@@ -3,9 +3,9 @@
|
||||
# Canale per filmpertutti.py
|
||||
# ------------------------------------------------------------
|
||||
|
||||
from core import httptools, support, scrapertools
|
||||
from core import httptools, support
|
||||
from core.item import Item
|
||||
from platformcode import config, logger
|
||||
from platformcode import config
|
||||
|
||||
def findhost(url):
|
||||
page = httptools.downloadpage(url).data
|
||||
@@ -15,20 +15,17 @@ def findhost(url):
|
||||
host = config.get_channel_url(findhost)
|
||||
headers = [['Referer', host]]
|
||||
|
||||
|
||||
@support.menu
|
||||
def mainlist(item):
|
||||
|
||||
film = ['/category/film/feed/',
|
||||
('Film al cinema', ['/category/ora-al-cinema/feed/', 'peliculas']),
|
||||
('Generi', ['/', 'genres']),
|
||||
('Saghe', ['/', 'genres', 'saghe']),
|
||||
film = ['/category/film/',
|
||||
('Generi', ['/category/film/', 'genres', 'lettersF'])
|
||||
]
|
||||
|
||||
tvshow = ['/category/serie-tv/feed/',
|
||||
]
|
||||
|
||||
anime = ['/category/anime/feed/',
|
||||
('SUB-ITA',['/category/anime-sub-ita/feed/', 'peliculas']),
|
||||
tvshow = ['/category/serie-tv/',
|
||||
('Aggiornamenti', ['/aggiornamenti-serie-tv/', 'peliculas', 'newest']),
|
||||
('Per Lettera', ['/category/serie-tv/', 'genres', 'lettersS'])
|
||||
]
|
||||
|
||||
search = ''
|
||||
@@ -37,107 +34,94 @@ def mainlist(item):
|
||||
|
||||
@support.scrape
|
||||
def peliculas(item):
|
||||
if not item.args == 'search': # pagination not works
|
||||
if not item.nextpage:
|
||||
item.page = 1
|
||||
else:
|
||||
item.page = item.nextpage
|
||||
support.info()
|
||||
# debug = True
|
||||
#debugBlock = True
|
||||
# support.dbg()
|
||||
|
||||
if not item.parent_url:
|
||||
item.parent_url = item.url
|
||||
if item.args != 'newest':
|
||||
patronBlock = r'<ul class="posts">(?P<block>.*)<\/ul>'
|
||||
patron = r'<li><a href="(?P<url>[^"]+)" data-thumbnail="(?P<thumb>[^"]+)">.*?<div class="title[^"]*">(?P<title>.+?)(?:\[(?P<lang>Sub-ITA)\])?(?:[ ]\[?(?P<quality>[HD]+)?\])?(?:[ ]\((?P<year>\d+)\)?)?<\/div>'
|
||||
patronNext = r'<a href="([^"]+)[^>]+>Pagina'
|
||||
else:
|
||||
patronBlock = r'<ul class="posts">(?P<block>.*)<div class="clear[^"]*">'
|
||||
patron = r'<li>\s?<a href="(?P<url>[^"]+)" data-thumbnail="(?P<thumb>[^"]+)">.*?<div class="title[^"]*">(?P<title>.+?)(?:\s\[(?P<quality>HD)\])?<\/div>\s*<div class="episode[^"]*"[^>]+>(?P<episode>[^<(]+)(?:\((?P<lang>[a-zA-Z\-]+)\))?'
|
||||
|
||||
if item.args == 'genres':
|
||||
action = 'check'
|
||||
|
||||
item.nextpage = item.page + 1
|
||||
nextPageUrl = "{}/?paged={}".format(item.parent_url, item.nextpage)
|
||||
patron= r'<item>\s<title>(?P<title>[^<]+?)\s*(\((?P<lang>Sub-[a-zA-Z]+)*\))?\s*(\[(?P<quality>[A-Z]*)\])?\s*(\((?P<year>[0-9]{4})\))?</title>.*?<link>(?P<url>.*?)</link>'
|
||||
def fullItemlistHook(itemlist):
|
||||
if len(itemlist) < 10:
|
||||
return itemlist[:-1:]
|
||||
else:
|
||||
return itemlist
|
||||
if item.args == 'search':
|
||||
action = 'check'
|
||||
elif item.contentType == 'tvshow':
|
||||
action = 'episodios'
|
||||
elif item.contentType == 'movie':
|
||||
action ='findvideos'
|
||||
else:
|
||||
action = 'check'
|
||||
patron= r'<article class=\"elementor-post.*?(<img .*?src=\"(?P<thumb>[^\"]+).*?)?<h3 class=\"elementor-post__title\".*?<a href=\"(?P<url>[^\"]+)\" >\s*(?P<title>[^<]+?)\s*(\((?P<lang>Sub-[a-zA-Z]+)*\))?\s*(\[(?P<quality>[A-Z]*)\])?\s*(\((?P<year>[0-9]{4})\))?\s+<'
|
||||
|
||||
def itemHook(item):
|
||||
item.title = item.title.replace(' - La Serie', '')
|
||||
return item
|
||||
|
||||
return locals()
|
||||
|
||||
@support.scrape
|
||||
def episodios(item):
|
||||
item.quality = ''
|
||||
data = item.data if item.data else httptools.downloadpage(item.url).data
|
||||
itemlist = []
|
||||
# debug = True
|
||||
data = support.match(item.url, headers=headers).data
|
||||
if 'accordion-item' in data:
|
||||
patronBlock = r'<span class="season[^>]*>\d+[^>]+>[^>]+>[^>]+>[^>]+>\D*(?:STAGIONE|Stagione)[ -]+(?P<lang>[a-zA-Z\- ]+)[^<]*</span>(?P<block>.*?)<div id="(?:season|disqus)'
|
||||
patron = r'<img src="(?P<thumb>[^"]+)"(?:[^>]*>){4}\s*<li class="season-no">(?P<season>\d+)(?:×|×|x)(?P<episode>\d+)[^<0-9]*<\/li>(?P<data>.*?javascript:;">(?P<title>[^<]+).*?</tbody>)'
|
||||
else:
|
||||
patronBlock = r'(?:STAGIONE|Stagione)(?:<[^>]+>)?\s*(?:(?P<lang>[A-Za-z- ]+))?(?P<block>.*?)(?: |<strong>|<div class="addtoany)'
|
||||
patron = r'(?:/>|p>)\s*(?P<season>\d+)(?:×|×|x)(?P<episode>\d+)[^<]+(?P<data>.*?)(?:<br|</p)'
|
||||
|
||||
for it in support.match(data, patron=[r'div class=\"single-season.*?(?P<id>season_[0-9]+).*?>Stagione:\s(?P<season>[0-9]+).*?(\s-\s(?P<lang>[a-zA-z]+?))?<']).matches:
|
||||
block = support.match(data, patron = r'div id=\"'+ it[0] +'\".*?</div').match
|
||||
for ep in support.match(block, patron=[r'<li><a href=\"(?P<url>[^\"]+).*?img\" src=\"(?P<thumb>[^\"]+).*?title\">(?P<episode>[0-9]+)\.\s+(?P<title>.*?)</span>']).matches:
|
||||
itemlist.append(item.clone(contentType = 'episode',
|
||||
action='findvideos',
|
||||
thumb=ep[1],
|
||||
episode=ep[2],
|
||||
season=it[1],
|
||||
contentSeason=it[1],
|
||||
contentEpisodeNumber=ep[2],
|
||||
title = support.format_longtitle(support.cleantitle(ep[3]), season = it[1], episode = ep[2], lang= it[3]),
|
||||
url = scrapertools.unescape(ep[0]), data = '')
|
||||
)
|
||||
def itemHook(i):
|
||||
i.url = item.url
|
||||
i.title.replace('×','x')
|
||||
if not i.contentLanguage:
|
||||
i.contentLanguage = 'ITA'
|
||||
return i
|
||||
return locals()
|
||||
|
||||
if config.get_setting('episode_info') and not support.stackCheck(['add_tvshow', 'get_newest']):
|
||||
support.tmdb.set_infoLabels_itemlist(itemlist, seekTmdb=True)
|
||||
support.check_trakt(itemlist)
|
||||
support.videolibrary(itemlist, item)
|
||||
if (config.get_setting('downloadenabled')):
|
||||
support.download(itemlist, item)
|
||||
|
||||
return itemlist
|
||||
|
||||
@support.scrape
|
||||
def genres(item):
|
||||
|
||||
if item.args == 'lettersF':
|
||||
item.contentType = 'movie'
|
||||
else:
|
||||
item.contentType = 'tvshow'
|
||||
|
||||
action = 'peliculas'
|
||||
blacklist = ['Tutti i film',]
|
||||
wantSaga = True if item.args == 'saghe' else False
|
||||
item.args = 'genres'
|
||||
patronBlock = r'<select class="cats">(?P<block>.*?)<\/select>'
|
||||
patronMenu = r'<option data-src="(?P<url>[^"]+)">(?P<title>[^<]+)<\/option>'
|
||||
|
||||
patronBlock = r'<nav class="elementor-nav-menu--main (?P<block>.*?)</nav>'
|
||||
patronMenu = r'<li class="menu-item.*?<a href="(?P<url>https:\/\/.*?)".*?>(?P<title>.*?)</a></li>'
|
||||
|
||||
def itemHook(item):
|
||||
item.url = "{}/feed/".format(item.url)
|
||||
return item
|
||||
|
||||
def itemlistHook(itemlist):
|
||||
itl = []
|
||||
for item in itemlist:
|
||||
isSaga = item.fulltitle.startswith('Saga')
|
||||
|
||||
if len(item.fulltitle) != 3:
|
||||
if (isSaga and wantSaga) or (not isSaga and not wantSaga):
|
||||
itl.append(item)
|
||||
return itl
|
||||
return locals()
|
||||
|
||||
|
||||
def check(item):
|
||||
item.data = httptools.downloadpage(item.url).data
|
||||
if 'season-details' in item.data.lower():
|
||||
item.contentType = 'tvshow'
|
||||
support.info()
|
||||
patron=r'class="taxonomy category"\s*><span property="name">([^>]+)</span></a><meta property="position" content="2">'
|
||||
block = support.match(item.url, patron=patron,headers=headers).match
|
||||
if block.lower() != 'film':
|
||||
support.info('select = ### è una serie ###')
|
||||
item.contentType='tvshow'
|
||||
return episodios(item)
|
||||
else:
|
||||
item.contentType = 'movie'
|
||||
support.info('select = ### è un movie ###')
|
||||
item.contentType='movie'
|
||||
return findvideos(item)
|
||||
|
||||
|
||||
def search(item, text):
|
||||
item.url = "{}/?{}".format(host, support.urlencode({'s': text}))
|
||||
def search(item, texto):
|
||||
support.info()
|
||||
item.url = host + "/search/" + texto
|
||||
item.args = 'search'
|
||||
|
||||
try:
|
||||
return peliculas(item)
|
||||
|
||||
# Continua la ricerca in caso di errore
|
||||
except:
|
||||
import sys
|
||||
for line in sys.exc_info():
|
||||
logger.error("search except: %s" % line)
|
||||
support.info("%s" % line)
|
||||
return []
|
||||
|
||||
|
||||
@@ -147,13 +131,13 @@ def newest(categoria):
|
||||
item = Item()
|
||||
try:
|
||||
if categoria == "peliculas":
|
||||
item.url = host + "/category/film/feed/"
|
||||
item.url = host + "/category/film/"
|
||||
item.action = "peliculas"
|
||||
item.extra = "movie"
|
||||
item.contentType = 'movie'
|
||||
itemlist = peliculas(item)
|
||||
else:
|
||||
item.url = host + "/category/serie-tv/feed/"
|
||||
item.url = host + "/aggiornamenti-serie-tv/"
|
||||
item.action = "peliculas"
|
||||
item.args = "newest"
|
||||
item.contentType = 'tvshow'
|
||||
@@ -170,16 +154,8 @@ def newest(categoria):
|
||||
|
||||
|
||||
def findvideos(item):
|
||||
video_url = item.url
|
||||
|
||||
if item.contentType == 'movie':
|
||||
video_url = support.match(item.url, patron=r'<a href="([^"]+)" rel="nofollow">').match
|
||||
|
||||
video_url = support.match(video_url, patron=r'<iframe src=\"(https://.*?)\"').match
|
||||
|
||||
if (video_url == ''):
|
||||
return []
|
||||
|
||||
itemlist = [item.clone(action="play", url=srv) for srv in support.match(video_url, patron='<div class=\"megaButton\" meta-type=\"v\" meta-link=\"([^\"]+).*?(?=>)>').matches]
|
||||
itemlist = support.server(item,itemlist=itemlist)
|
||||
return itemlist
|
||||
data = support.match(item.url, patron=r'<a target="_blank" rel="nofollow" href="([^"]+)">').matches
|
||||
return support.server(item, data=data, patronTag='Versione: <[^>]+>([^<]+)')
|
||||
else:
|
||||
return support.server(item, item.data)
|
||||
|
||||
2
channels/filmstreaming.json
Executable file → Normal file
2
channels/filmstreaming.json
Executable file → Normal file
@@ -2,7 +2,7 @@
|
||||
"id": "filmstreaming",
|
||||
"name": "Film Streaming",
|
||||
"language": ["ita"],
|
||||
"active": false,
|
||||
"active": true,
|
||||
"thumbnail": "filmstreaming.png",
|
||||
"banner": "filmstreaming.png",
|
||||
"categories": ["movie"],
|
||||
|
||||
0
channels/filmstreaming.py
Executable file → Normal file
0
channels/filmstreaming.py
Executable file → Normal file
0
channels/guardaseriecam.json
Executable file → Normal file
0
channels/guardaseriecam.json
Executable file → Normal file
8
channels/guardaseriecam.py
Executable file → Normal file
8
channels/guardaseriecam.py
Executable file → Normal file
@@ -36,7 +36,7 @@ def list(item):
|
||||
@support.scrape
|
||||
def peliculas(item):
|
||||
# debug = True
|
||||
patron = r'<div class="mlnh-thumb"><a href="(?P<url>[^"]+)[^>]+title="(?P<title>[^"]+).*?<img src="(?P<thumb>[^"]+).*?hdn">[^<]*(?P<year>[0-9]{4})'
|
||||
patron = r'<div class="mlnh-thumb"><a href="(?P<url>[^"]+).*?title="(?P<title>[^"]+).*?src="(?P<thumb>[^"]+).*?hdn">(?P<year>[0-9]{4})'
|
||||
patronNext = 'pagenavi.*?<a href="([^"]+)">\d+'
|
||||
action = 'episodios'
|
||||
return locals()
|
||||
@@ -45,9 +45,9 @@ def peliculas(item):
|
||||
@support.scrape
|
||||
def episodios(item):
|
||||
patronBlock = r'<div class="tab-pane fade" id="season-(?P<season>.)"(?P<block>.*?)</ul>\s*</div>'
|
||||
patron = r'(?P<data><a href="#" allowfullscreen data-link="[^"]+.*?title="(?P<title>[^"]+)(?P<lang>[sS][uU][bB]-?[iI][tT][aA])?\s*">(?P<episode>[^<]+).*?</li>)'
|
||||
patron = r'<a href="#" allowfullscreen data-link="(?P<url>[^"]+).*?title="(?P<title>[^"]+)(?P<lang>[sS][uU][bB]-?[iI][tT][aA])?\s*">(?P<episode>[^<]+)'
|
||||
action = 'findvideos'
|
||||
# debug = True
|
||||
# debugBlock = True
|
||||
return locals()
|
||||
|
||||
|
||||
@@ -68,4 +68,4 @@ def search(item, text):
|
||||
|
||||
def findvideos(item):
|
||||
logger.debug()
|
||||
return support.server(item, item.data)
|
||||
return support.server(item, item.url)
|
||||
0
channels/guardaserieclick.json
Executable file → Normal file
0
channels/guardaserieclick.json
Executable file → Normal file
0
channels/guardaserieclick.py
Executable file → Normal file
0
channels/guardaserieclick.py
Executable file → Normal file
0
channels/guardaserieicu.json
Executable file → Normal file
0
channels/guardaserieicu.json
Executable file → Normal file
0
channels/guardaserieicu.py
Executable file → Normal file
0
channels/guardaserieicu.py
Executable file → Normal file
0
channels/hd4me.json
Executable file → Normal file
0
channels/hd4me.json
Executable file → Normal file
2
channels/hd4me.py
Executable file → Normal file
2
channels/hd4me.py
Executable file → Normal file
@@ -57,7 +57,5 @@ def search(item, text):
|
||||
|
||||
def findvideos(item):
|
||||
url = support.match(item, patron=r'<a class=["]?bot1["]? href="([^"]+)"').match
|
||||
if not url.startswith('http'):
|
||||
url = host + url
|
||||
url = support.httptools.downloadpage(url, followredirect=True).url
|
||||
return support.server(item, url)
|
||||
|
||||
0
channels/ilcorsaronero.json
Executable file → Normal file
0
channels/ilcorsaronero.json
Executable file → Normal file
71
channels/ilcorsaronero.py
Executable file → Normal file
71
channels/ilcorsaronero.py
Executable file → Normal file
@@ -3,59 +3,90 @@
|
||||
# Canale per ilcorsaronero
|
||||
# ------------------------------------------------------------
|
||||
|
||||
from core import support, httptools
|
||||
from core import support
|
||||
|
||||
# def findhost(url):
|
||||
# data = support.httptools.downloadpage(url).data
|
||||
# url = support.scrapertools.find_single_match(data, '<li><a href="([^"]+)')
|
||||
# return url[:-1] if url.endswith('/') else url
|
||||
|
||||
host = support.config.get_channel_url()
|
||||
support.info('HOST',host)
|
||||
# host = 'https://ilcorsaronero.xyz'
|
||||
headers = [['Referer', host]]
|
||||
|
||||
|
||||
@support.menu
|
||||
def mainlist(item):
|
||||
|
||||
menu = [
|
||||
('Film {film}', ['/cat/film', 'peliculas', [0, 'movie', True], 'undefined']),
|
||||
('Serie TV', ['/cat/serie-tv', 'peliculas', [0 , 'tvshow', True], 'undefined']),
|
||||
('Animazione', ['/cat/animazione', 'peliculas', [0 , 'anime', True], 'undefined']),
|
||||
('Documentari', ['/cat/altro/documentari', 'peliculas', [0 , 'documentary', True], 'undefined']),
|
||||
('Programmi TV', ['/cat/altro/programmi-tv', 'peliculas', [0 , 'tvshow', True], 'tvshow']),
|
||||
('Video Musica', ['/cat/musica/video-musicali', 'peliculas', [0 , 'music', False], 'undefined']),
|
||||
('Videocorsi', ['/cat/altro/videocorsi', 'peliculas', [0 , 'music', False], 'undefined'])
|
||||
('BDRiP {film}', ['/categoria.php?active=0&category=1&order=data&by=DESC&page=', 'peliculas', [0, 'movie', True], 'undefined']),
|
||||
('Cerca BDRiP... {submenu} {film}', ['/torrent-ita/1/', 'search', ['search', 'movie', True], 'movie']),
|
||||
('DVD {film}', ['/categoria.php?active=0&category=20&order=data&by=DESC&page=', 'peliculas', [0, 'movie', True], 'undefined']),
|
||||
('Cerca DVD... {submenu} {film}', ['/torrent-ita/20/', 'search', ['search', 'movie', True], 'movie']),
|
||||
('Screener {film}', ['/categoria.php?active=0&category=19&order=data&by=DESC&page=', 'peliculas', [0, 'movie', True], 'undefined']),
|
||||
('Cerca Screener.. {submenu} {film}', ['/torrent-ita/19/', 'search', ['search', 'movie', True], 'movie']),
|
||||
('Serie TV', ['/categoria.php?active=0&category=15&order=data&by=DES&page=', 'peliculas', [0 , 'tvshow', True], 'tvshow']),
|
||||
('Cerca Serie TV.. {submenu}', ['/torrent-ita/15/', 'search', ['search', 'tvshow',True], 'tvshow']),
|
||||
('Anime', ['/categoria.php?active=0&category=5&order=data&by=DESC&page=', 'peliculas', [0, 'anime', True], 'tvshow']),
|
||||
('Cerca Anime.. {submenu}', ['/torrent-ita/5/', 'search', ['search', 'anime', True], 'tvshow']),
|
||||
('Musica', ['/categoria.php?active=0&category=2&order=data&by=DESC&page=', 'peliculas', [0, 'music', False], 'music']),
|
||||
('Cerca Musica.. {submenu}', ['/torrent-ita/2/', 'search', ['search', 'music', False], 'music']),
|
||||
('Audiolibri {musica}', ['/categoria.php?active=0&category=18&order=data&by=DESC&page=', 'peliculas', [0, 'music', False], 'music']),
|
||||
('Cerca Audiolibri.. {submenu}', ['/torrent-ita/18/', 'search', ['search', 'music', False], 'music']),
|
||||
# mostrerebbe anche risultati non "multimediali" e allungherebbero inutilmente la ricerca globale
|
||||
# ('Altro {film}', ['/categoria.php?active=0&category=4&order=data&by=DESC&page=', 'peliculas', [0, 'other', False]]),
|
||||
# ('Cerca altro.. {submenu}', ['/torrent-ita/4/', 'search', ['search', 'other', False]]),
|
||||
# ('Cerca Tutto... {color kod bold}', ['/argh.php?search=', 'search', ['search', 'all', False]])
|
||||
]
|
||||
search = ''
|
||||
|
||||
return locals()
|
||||
|
||||
|
||||
@support.scrape
|
||||
def peliculas(item):
|
||||
debug = False
|
||||
# debug = True
|
||||
action = 'findvideos'
|
||||
sceneTitle = item.args[2]
|
||||
sceneTitle = item.args[2]
|
||||
if item.args[1] in ['tvshow', 'anime', 'music', 'other']:
|
||||
patron = r'>[^"<]+'
|
||||
else:
|
||||
patron = r'>(?P<quality>[^"<]+)'
|
||||
patron += '<TD[^>]+><A class="tab" HREF="(?P<url>[^"]+)"\s*>[^<]+<[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>(?P<size>[^<]+)<[^>]+>[^>]+>[^>]+><form action="[^"]+/\d+/(?P<title>[^"]+)[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>[^>]+>(?P<seed>[^<]+)'
|
||||
|
||||
def itemHook(item):
|
||||
if not sceneTitle:
|
||||
item.title = item.title.replace('_', ' ')
|
||||
item.fulltitle = item.fulltitle.replace('_', ' ')
|
||||
item.title = support.scrapertools.decodeHtmlentities(support.urlparse.unquote(item.title))
|
||||
|
||||
return item
|
||||
|
||||
patron = r'<a class="hover:underline line-clamp-1.*?href="(?P<url>[^"]+)"\s*>(?P<title>.*?)</a>[^>]+>[^>]+>[^>]+>(?P<seed>.*?)<'
|
||||
patronNext = r'<a href="(?P<url>[^"]+)".*?Next</span>'
|
||||
if 'search' not in item.args:
|
||||
item.url += str(item.args[0])
|
||||
def itemlistHook(itemlist):
|
||||
args = item.args
|
||||
args[0] += 1
|
||||
support.nextPage(itemlist, item, next_page=item.url, function_or_level="peliculas")
|
||||
# itemlist.append(item.clone(title=support.typo(support.config.get_localized_string(30992), 'color kod bold'), args=args, thumbnail=support.thumb()))
|
||||
return itemlist
|
||||
return locals()
|
||||
|
||||
def search(item, text):
|
||||
item.url = "{}/search?{}".format(host, support.urlencode({'q': text}))
|
||||
item.args = 'search'
|
||||
|
||||
def search(item, text):
|
||||
support.info(item, text)
|
||||
if 'all' in item.args:
|
||||
item.url += text
|
||||
else:
|
||||
item.url += text + '.html'
|
||||
try:
|
||||
return peliculas(item)
|
||||
|
||||
# Cattura la eccezione così non interrompe la ricerca globle se il canale si rompe!
|
||||
except:
|
||||
import sys
|
||||
for line in sys.exc_info():
|
||||
logger.error("search except: %s" % line)
|
||||
support.logger.error("search except: %s" % line)
|
||||
return []
|
||||
|
||||
|
||||
def findvideos(item):
|
||||
if item.contentType == 'tvshow': item.contentType = 'episode'
|
||||
Videolibrary = True if 'movie' in item.args else False
|
||||
|
||||
0
channels/ilgeniodellostreaming.json
Executable file → Normal file
0
channels/ilgeniodellostreaming.json
Executable file → Normal file
0
channels/ilgeniodellostreaming.py
Executable file → Normal file
0
channels/ilgeniodellostreaming.py
Executable file → Normal file
0
channels/ilgeniodellostreaming_cam.json
Executable file → Normal file
0
channels/ilgeniodellostreaming_cam.json
Executable file → Normal file
0
channels/ilgeniodellostreaming_cam.py
Executable file → Normal file
0
channels/ilgeniodellostreaming_cam.py
Executable file → Normal file
@@ -1,11 +0,0 @@
|
||||
{
|
||||
"id": "italiafilm",
|
||||
"name": "ItaliaFilm",
|
||||
"language": ["ita", "sub-ita"],
|
||||
"active": true,
|
||||
"thumbnail": "italiafilm.png",
|
||||
"banner": "",
|
||||
"categories": ["movie"],
|
||||
"not_active": ["include_in_newest"],
|
||||
"settings": []
|
||||
}
|
||||
@@ -1,90 +0,0 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# ------------------------------------------------------------
|
||||
# Canale per 'italifilm'
|
||||
# ------------------------------------------------------------
|
||||
|
||||
from core import support, httptools, scrapertools, tmdb
|
||||
from platformcode import config, logger
|
||||
|
||||
host = config.get_channel_url()
|
||||
headers = [['Referer', host]]
|
||||
|
||||
|
||||
@support.menu
|
||||
def mainlist(item):
|
||||
menu = [
|
||||
('Film', ['/film/', 'list', 'film']),
|
||||
('Per Genere', ['', 'list', 'genere']),
|
||||
('Al Cinema', ['/cinema/', 'list', 'film']),
|
||||
('Sub-ITA', ['/sub-ita/', 'list', 'film']),
|
||||
('Top del Mese', ['/top-del-mese.html', 'list', 'film'])
|
||||
]
|
||||
search = ''
|
||||
|
||||
return locals()
|
||||
|
||||
|
||||
@support.scrape
|
||||
def list(item):
|
||||
actLike = 'peliculas'
|
||||
if item.args == 'genere':
|
||||
patronBlock = r'<ul class="sub-menu">(?P<block>.*?)</ul>'
|
||||
patronMenu = r'<li><a href="(?P<url>[^"]+)">(?P<title>[^<]+)'
|
||||
action = 'peliculas'
|
||||
elif item.args == 'film':
|
||||
patron = r'<div class="entry-summary.*?<a href="(?P<url>[^"]+)" title="(?P<title>[^\("]+)(?:\((?P<year>\d+)\))" class="[^"]+"><img class="lazyload" data-src="(?P<thumb>[^"]+)" alt="[^"]+".*?></a>'
|
||||
patronNext = r'<a href="([^"]+)">(?:&rarr|→)'
|
||||
|
||||
return locals()
|
||||
|
||||
def peliculas(item):
|
||||
data = httptools.downloadpage(item.url).data
|
||||
itemlist = []
|
||||
for it in support.match(data, patron=[r'<div class="entry-summary.*?<a href="(?P<url>[^"]+)" title="(?P<title>[^"]+)(?:\((?P<year>\d+)\))" class="[^"]+"><img class="lazyload" data-src="(?P<thumb>[^"]+)" alt="[^"]+".*?></a>']).matches:
|
||||
infoLabels = dict()
|
||||
infoLabels['title'] = it[1]
|
||||
infoLabels['mediatype'] = 'movie'
|
||||
infoLabels['year'] = it[2]
|
||||
itemlist.append(item.clone(action='findvideos', thumbnail = host + it[3].replace(' ','%20'), title = support.cleantitle(it[1]), url= it[0], infoLabels=infoLabels))
|
||||
|
||||
tmdb.set_infoLabels_itemlist(itemlist, seekTmdb=True)
|
||||
if item.args == 'search':
|
||||
next = support.match(data, patron=['<a name="nextlink".*list_submit\((\d+)\);.*(?:&rarr|→)']).matches
|
||||
else:
|
||||
next = support.match(data, patron=['<a href="([^"]+)">(?:&rarr|→)']).matches
|
||||
|
||||
if next:
|
||||
if item.args == 'search':
|
||||
item.url = "{}/?{}".format(host, support.urlencode({"story": item.search_text,"do": "search","subaction": "search", "search_start": next[0]}))
|
||||
else:
|
||||
item.url = next[0]
|
||||
support.nextPage(itemlist = itemlist, item = item, next_page=item.url)
|
||||
|
||||
return itemlist
|
||||
|
||||
|
||||
def search(item, text):
|
||||
item.args = 'search'
|
||||
item.url = "{}/?{}".format(host, support.urlencode({"story": text,"do": "search","subaction": "search", "search_start": item.page}))
|
||||
item.search_text = text
|
||||
try:
|
||||
return peliculas(item)
|
||||
|
||||
except:
|
||||
import sys
|
||||
for line in sys.exc_info():
|
||||
logger.error("search except: %s" % line)
|
||||
return []
|
||||
|
||||
#action di default
|
||||
def findvideos(item):
|
||||
|
||||
support.info('findvideos')
|
||||
urls = []
|
||||
data = support.match(item).data
|
||||
matches = support.match(data, patron=r'<iframe.*?src="([^"]+)').matches
|
||||
|
||||
for m in matches:
|
||||
if 'youtube' not in m and not m.endswith('.js'):
|
||||
urls += support.match(m, patron=r'data-link="([^"]+)').matches
|
||||
return support.server(item, urls)
|
||||
0
channels/italiaserie.json
Executable file → Normal file
0
channels/italiaserie.json
Executable file → Normal file
0
channels/italiaserie.py
Executable file → Normal file
0
channels/italiaserie.py
Executable file → Normal file
0
channels/la7.json
Executable file → Normal file
0
channels/la7.json
Executable file → Normal file
45
channels/la7.py
Executable file → Normal file
45
channels/la7.py
Executable file → Normal file
@@ -4,8 +4,7 @@
|
||||
# ------------------------------------------------------------
|
||||
|
||||
import requests
|
||||
from core import support, httptools
|
||||
from platformcode import logger
|
||||
from core import support
|
||||
|
||||
DRM = 'com.widevine.alpha'
|
||||
key_widevine = "https://la7.prod.conax.cloud/widevine/license"
|
||||
@@ -28,7 +27,7 @@ def mainlist(item):
|
||||
('Replay {bold}', ['', 'replay_channels'])]
|
||||
|
||||
menu = [('Programmi TV {bullet bold}', ['/tutti-i-programmi', 'peliculas', '', 'tvshow']),
|
||||
('Teche La7 {bullet bold}', ['/la7teche', 'peliculas', '', 'tvshow'])]
|
||||
('Teche La7 {bullet bold}', ['/i-protagonisti', 'peliculas', '', 'tvshow'])]
|
||||
|
||||
search = ''
|
||||
return locals()
|
||||
@@ -84,18 +83,13 @@ def search(item, text):
|
||||
@support.scrape
|
||||
def peliculas(item):
|
||||
search = item.search
|
||||
action = 'episodios'
|
||||
pagination = 20
|
||||
disabletmdb = True
|
||||
addVideolibrary = False
|
||||
downloadEnabled = False
|
||||
|
||||
action = 'episodios'
|
||||
patron = r'<a href="(?P<url>[^"]+)"[^>]+><div class="[^"]+" data-background-image="(?P<t>[^"]+)"></div><div class="titolo">\s*(?P<title>[^<]+)<'
|
||||
|
||||
if 'la7teche' in item.url:
|
||||
patron = r'<a href="(?P<url>[^"]+)" title="(?P<title>[^"]+)" class="teche-i-img".*?url\(\'(?P<thumb>[^\']+)'
|
||||
|
||||
def itemHook(item):
|
||||
item.thumbnail = 'http:' + item.t if item.t.startswith('//') else item.t if item.t else item.thumbnail
|
||||
item.fanart = item.thumb
|
||||
return item
|
||||
return locals()
|
||||
@@ -103,18 +97,33 @@ def peliculas(item):
|
||||
|
||||
@support.scrape
|
||||
def episodios(item):
|
||||
data = support.match(item).data
|
||||
# debug = True
|
||||
action = 'findvideos'
|
||||
if '>puntate<' in data:
|
||||
patronBlock = r'>puntate<(?P<block>.*?)home-block-outbrain'
|
||||
url = support.match(data, patron=r'>puntate<[^>]+>[^>]+>[^>]+><a href="([^"]+)"').match
|
||||
data += support.match(host + url).data
|
||||
else:
|
||||
item.url += '/video'
|
||||
data = support.match(item).data
|
||||
|
||||
patron = r'(?:<a href="(?P<url>[^"]+)">[^>]+><div class="[^"]+" data-background-image="(?P<t>[^"]*)">[^>]+>[^>]+>[^>]+>(?:[^>]+>)?(?:[^>]+>){6}?)\s*(?P<title>[^<]+)<(?:[^>]+>[^>]+>[^>]+><div class="data">(?P<date>[^<]+))?|class="heading">[^>]+>(?P<Title>[^<]+).*?window.shareUrl = "(?P<Url>[^"]+)".*?poster:\s*"(?P<Thumb>[^"]+)", title: "(?P<desc>[^"]+)"'
|
||||
patronNext = r'<a href="([^"]+)">›'
|
||||
addVideolibrary = False
|
||||
downloadEnabled = False
|
||||
|
||||
if 'la7teche' in item.url:
|
||||
patron = r'<a href="(?P<url>[^"]+)">\s*<div class="holder-bg">.*?data-background-image="(?P<thumb>[^"]+)(?:[^>]+>){4}\s*(?P<title>[^<]+)(?:(?:[^>]+>){2}\s*(?P<plot>[^<]+))?'
|
||||
else:
|
||||
data = str(support.match(item.url, patron=r'"home-block home-block--oggi(.*?)</section>').matches)
|
||||
data += httptools.downloadpage(item.url + '/video').data
|
||||
|
||||
patron = r'item[^>]+>\s*<a href="(?P<url>[^"]+)">.*?image="(?P<thumb>[^"]+)(?:[^>]+>){4,5}\s*(?P<title>[\d\w][^<]+)(?:(?:[^>]+>){7}\s*(?P<title2>[\d\w][^<]+))?'
|
||||
patronNext = r'<a href="([^"]+)">›'
|
||||
def itemHook(item):
|
||||
if item.Thumb: item.t = item.Thumb
|
||||
item.thumbnail = 'http:' + item.t if item.t.startswith('//') else item.t if item.t else item.thumbnail
|
||||
if item.Title: item.title = support.typo(item.Title, 'bold')
|
||||
if item.date:
|
||||
item.title = support.re.sub(r'[Pp]untata (?:del )?\d+/\d+/\d+', '', item.title)
|
||||
item.title += support.typo(item.date, '_ [] bold')
|
||||
if item.desc: item.plot = item.desc
|
||||
item.forcethumb = True
|
||||
item.fanart = item.thumbnail
|
||||
return item
|
||||
return locals()
|
||||
|
||||
|
||||
|
||||
0
channels/mediasetplay.json
Executable file → Normal file
0
channels/mediasetplay.json
Executable file → Normal file
29
channels/mediasetplay.py
Executable file → Normal file
29
channels/mediasetplay.py
Executable file → Normal file
@@ -38,8 +38,8 @@ sid = res.json()['response']['sid']
|
||||
session.headers.update({'authorization': 'Bearer ' + Token})
|
||||
|
||||
# sessione
|
||||
#sessionKey = session.get(sessionUrl.format(uuid=str(uuid.uuid4())), verify=False).json()['sessionKey']
|
||||
#session.headers.update({'x-session': sessionKey})
|
||||
sessionKey = session.get(sessionUrl.format(uuid=str(uuid.uuid4())), verify=False).json()['sessionKey']
|
||||
session.headers.update({'x-session': sessionKey})
|
||||
|
||||
pagination = [10, 20, 30, 40, 50, 60, 70, 80, 90, 100][config.get_setting('pagination', 'mediasetplay')]
|
||||
|
||||
@@ -48,20 +48,11 @@ pagination = [10, 20, 30, 40, 50, 60, 70, 80, 90, 100][config.get_setting('pagin
|
||||
def mainlist(item):
|
||||
top = [('Dirette {bold}', ['', 'live'])]
|
||||
|
||||
menu = [('Film Più Visti {submenu}', ['/cinema', 'peliculas', {'uxReference':'filmPiuVisti24H'}, 'movie']),
|
||||
('Film ultimi arrivi {submenu}', ['/cinema', 'peliculas', {'uxReference':'filmUltimiArrivi'}, 'movie']),
|
||||
('Film Da Non Perdere {submenu}', ['/cinema', 'peliculas', {'uxReference':'filmClustering'}, 'movie']),
|
||||
('Fiction e Serie Tv del momento {submenu}', ['/fiction', 'peliculas', {'uxReference':'fictionSerieTvDelMomento'}, 'tvshow']),
|
||||
('Serie TV Piu Viste {submenu}', ['/fiction', 'peliculas', {'uxReference':'serieTvPiuViste24H'}, 'tvshow']),
|
||||
('Soap del momento {submenu}', ['/cinema', 'peliculas', {'uxReference':'fictionSerieTvParamsGenre', 'params': 'genre≈Soap opera'}, 'tvshow']),
|
||||
('Programmi TV Prima serata{ submenu}', ['/programmitv', 'peliculas', {'uxReference':'stagioniPrimaSerata'}, 'tvshow']),
|
||||
('Programmi TV Daytime{ submenu}', ['/programmitv', 'peliculas', {'uxReference':'stagioniDaytime'}, 'tvshow']),
|
||||
('Talent e reality {submenu}', ['/talent', 'peliculas', {'uxReference':'multipleBlockProgrammiTv', 'userContext' :'iwiAeyJwbGF0Zm9ybSI6IndlYiJ9Aw'}, 'tvshow']),
|
||||
('Kids Evergreen {submenu}', ['/kids', 'peliculas', {'uxReference':'kidsMediaset' }, 'undefined']),
|
||||
('Kids Boing {submenu}', ['/kids', 'peliculas', {'uxReference':'kidsBoing' }, 'undefined']),
|
||||
('Kids Cartoonito {submenu}', ['/kids', 'peliculas', {'uxReference':'kidsCartoonito' }, 'undefined']),
|
||||
('Documentari più visti {submenu}', ['/documentari', 'peliculas', {'uxReference': 'documentariPiuVisti24H'}, 'undefined']),
|
||||
]
|
||||
menu = [('Film {bullet bold}', ['/cinema', 'peliculas', {'uxReference':'filmUltimiArrivi'}, 'movie']),
|
||||
('Fiction / Serie TV {bullet bold}', ['/fiction', 'menu', '5acfcb3c23eec6000d64a6a4', 'tvshow']),
|
||||
('Programmi TV{ bullet bold}', ['/programmitv', 'menu', '5acfc8011de1c4000b6ec953', 'tvshow']),
|
||||
('Documentari {bullet bold}', ['/documentari', 'menu', '5bfd17c423eec6001aec49f9', 'undefined']),
|
||||
('Kids {bullet bold}', ['/kids', 'menu', '5acfcb8323eec6000d64a6b3', 'undefined'])]
|
||||
|
||||
search = ''
|
||||
return locals()
|
||||
@@ -218,7 +209,7 @@ def episodios(item):
|
||||
order = 'desc' if '/programmi-tv/' in item.url else 'asc'
|
||||
|
||||
itemlist = []
|
||||
res = requests.get('https://feed.entertainment.tv.theplatform.eu/f/PR1GhC/mediaset-prod-all-programs-v2?byCustomValue={subBrandId}{' + item.subbrand +'}&range=0-10000&sort=:publishInfo_lastPublished|' + order + ',tvSeasonEpisodeNumber').json()['entries']
|
||||
res = requests.get('https://feed.entertainment.tv.theplatform.eu/f/PR1GhC/mediaset-prod-all-programs-v2?byCustomValue={subBrandId}{' + item.subbrand +'}&sort=:publishInfo_lastPublished|' + order + ',tvSeasonEpisodeNumber').json()['entries']
|
||||
|
||||
for it in res:
|
||||
thumb = ''
|
||||
@@ -301,8 +292,8 @@ def findvideos(item):
|
||||
|
||||
|
||||
def get_from_id(item):
|
||||
#sessionKey = session.get(sessionUrl.format(uuid=str(uuid.uuid4())), verify=False).json()['sessionKey']
|
||||
#session.headers.update({'x-session': sessionKey})
|
||||
sessionKey = session.get(sessionUrl.format(uuid=str(uuid.uuid4())), verify=False).json()['sessionKey']
|
||||
session.headers.update({'x-session': sessionKey})
|
||||
res = session.get(entry.format(id=item.args)).json()
|
||||
if 'components' in res:
|
||||
id = quote(",".join(res["components"]))
|
||||
|
||||
0
channels/mediasetplay.py.old
Executable file → Normal file
0
channels/mediasetplay.py.old
Executable file → Normal file
2
channels/metalvideo.json
Executable file → Normal file
2
channels/metalvideo.json
Executable file → Normal file
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"id": "metalvideo",
|
||||
"name": "Metal Video",
|
||||
"active": false,
|
||||
"active": true,
|
||||
"language": ["*"],
|
||||
"thumbnail": "metalvideo.png",
|
||||
"banner": "metalvideo.png",
|
||||
|
||||
37
channels/metalvideo.py
Executable file → Normal file
37
channels/metalvideo.py
Executable file → Normal file
@@ -9,33 +9,37 @@ host = 'https://metalvideo.com'
|
||||
headers = {'X-Requested-With': 'XMLHttpRequest'}
|
||||
|
||||
|
||||
@support.menu
|
||||
def mainlist(item):
|
||||
menu = [('Generi',['', 'genres']),
|
||||
('Ultimi Video',['/videos/latest', 'peliculas']),
|
||||
('Top Video',['/videos/top', 'peliculas']),
|
||||
('Cerca...',['','search',])]
|
||||
return locals()
|
||||
|
||||
|
||||
@support.scrape
|
||||
def genres(item):
|
||||
def mainlist(item):
|
||||
item.url = host
|
||||
action = 'peliculas'
|
||||
patronBlock = r'<div class="swiper-slide">(?P<block>.*?)<button'
|
||||
patron = r'class="" href="(?P<url>[^"]+)[^>]+>(?P<title>[^<]+)<'
|
||||
patronBlock = r'<ul class="dropdown-menu(?P<block>.*?)</ul>\s*</div'
|
||||
patron = r'<a href="(?P<url>[^"]+)"(?: class="")?>(?P<title>[^<]+)<'
|
||||
def itemHook(item):
|
||||
item.thumbnail = support.thumb('music')
|
||||
item.contentType = 'music'
|
||||
return item
|
||||
def itemlistHook(itemlist):
|
||||
itemlist.pop(0)
|
||||
itemlist.append(
|
||||
support.Item(
|
||||
channel=item.channel,
|
||||
title=support.typo('Cerca...', 'bold'),
|
||||
contentType='music',
|
||||
url=item.url,
|
||||
action='search',
|
||||
thumbnail=support.thumb('search')))
|
||||
|
||||
support.channel_config(item, itemlist)
|
||||
return itemlist
|
||||
return locals()
|
||||
|
||||
@support.scrape
|
||||
def peliculas(item):
|
||||
# debug=True
|
||||
action = 'findvideos'
|
||||
patron= r'<a href="(?P<url>[^"]+)"[^>]+>\s*<img src="(?P<thumb>[^"]+)" alt="(?P<title>[^"]+)"[^>]*>'
|
||||
patronNext = r'<a href="([^"]+)" data-load="[^"]+" class="[^"]+" title="Next'
|
||||
patron= r'<img src="[^"]+" alt="(?P<title>[^"]+)" data-echo="(?P<thumb>[^"]+)"(?:[^>]+>){7}<a href="(?P<url>[^"]+)"'
|
||||
patronNext = r'<a href="([^"]+)">(?:»|»)'
|
||||
typeContentDict = {'': 'music'}
|
||||
def itemHook(item):
|
||||
item.contentType = 'music'
|
||||
@@ -45,13 +49,12 @@ def peliculas(item):
|
||||
|
||||
|
||||
def findvideos(item):
|
||||
data = support.match(item, patron=r'<source src="[^"]+').match
|
||||
return support.server(item, Videolibrary=False, data=data)
|
||||
return support.server(item, Videolibrary=False)
|
||||
|
||||
|
||||
def search(item, text):
|
||||
support.info(text)
|
||||
item.url = host + '/search?keyword=' + text
|
||||
item.url = host + '/search.php?keywords=' + text + '&video-id='
|
||||
try:
|
||||
return peliculas(item)
|
||||
# Continua la ricerca in caso di errore
|
||||
|
||||
0
channels/mondoserietv.json
Executable file → Normal file
0
channels/mondoserietv.json
Executable file → Normal file
0
channels/mondoserietv.py
Executable file → Normal file
0
channels/mondoserietv.py
Executable file → Normal file
0
channels/paramount.json
Executable file → Normal file
0
channels/paramount.json
Executable file → Normal file
0
channels/paramount.py
Executable file → Normal file
0
channels/paramount.py
Executable file → Normal file
0
channels/piratestreaming.json
Executable file → Normal file
0
channels/piratestreaming.json
Executable file → Normal file
0
channels/piratestreaming.py
Executable file → Normal file
0
channels/piratestreaming.py
Executable file → Normal file
0
channels/plutotv.json
Executable file → Normal file
0
channels/plutotv.json
Executable file → Normal file
12
channels/plutotv.py
Executable file → Normal file
12
channels/plutotv.py
Executable file → Normal file
@@ -6,7 +6,7 @@
|
||||
import uuid, datetime
|
||||
from platformcode import logger, config
|
||||
from core.item import Item
|
||||
from core import jsontools, support, httptools
|
||||
from core import support, httptools
|
||||
|
||||
host = support.config.get_channel_url()
|
||||
|
||||
@@ -14,20 +14,17 @@ api = 'https://api.pluto.tv'
|
||||
UUID = 'sid={}&deviceId={}'.format(uuid.uuid1().hex, uuid.uuid4().hex)
|
||||
vod_url = '{}/v3/vod/categories?includeItems=true&deviceType=web&'.format(api, UUID)
|
||||
|
||||
|
||||
@support.menu
|
||||
def mainlist(item):
|
||||
top = [('Dirette {bold}', ['/it/live-tv/', 'live'])]
|
||||
|
||||
menu = [('Categorie', ['', 'category'])]
|
||||
menu = sorted([(it['name'], ['/it/on-demand', 'peliculas', it['items']]) for it in httptools.downloadpage(vod_url).json['categories'][1:]])
|
||||
|
||||
search = ''
|
||||
|
||||
return locals()
|
||||
|
||||
@support.menu
|
||||
def category(item):
|
||||
menu = sorted([(it['name'], ['/it/on-demand', 'peliculas', it['items']]) for it in httptools.downloadpage(vod_url).json['categories'][1:]])
|
||||
return locals()
|
||||
|
||||
def live(item):
|
||||
logger.debug()
|
||||
@@ -78,7 +75,6 @@ def peliculas(item):
|
||||
logger.debug()
|
||||
itemlist = []
|
||||
recordlist = []
|
||||
|
||||
for i, it in enumerate(item.args):
|
||||
if item.search in it['name'].lower():
|
||||
itm = Item(channel=item.channel,
|
||||
@@ -92,7 +88,7 @@ def peliculas(item):
|
||||
thumbnail= it['covers'][0]['url'],
|
||||
fanart= it['covers'][2]['url'] if len(it['covers']) > 2 else '',
|
||||
id= it['_id'],
|
||||
videourl= it.get('stitched', {}).get('urls', [{}])[0].get('url','').split('?')[0])
|
||||
videourl= it['stitched']['urls'][0]['url'].split('?')[0])
|
||||
|
||||
if i < 20 or item.search:
|
||||
itemlist.append(itm)
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user