Various fixes due to layout changes (#97)
* Various fixes due to layout changes * Update .pylintrc
This commit is contained in:
parent
e07edfa658
commit
13af7437af
@ -21,3 +21,4 @@ disable=
|
||||
|
||||
super-with-arguments, # Python 2.7 compatibility
|
||||
raise-missing-from, # Python 2.7 compatibility
|
||||
consider-using-f-string, # Python 2.7 compatibility
|
||||
|
@ -113,7 +113,7 @@ class Catalog:
|
||||
},
|
||||
info_dict={
|
||||
'tvshowtitle': program.title,
|
||||
'title': kodiutils.localize(30205, season=season.number), # Season {season}
|
||||
'title': kodiutils.localize(30205, season=season.number) if season.number else season.title, # Season {season}
|
||||
'plot': season.description or program.description,
|
||||
'set': program.title,
|
||||
}
|
||||
@ -243,6 +243,7 @@ class Catalog:
|
||||
listing = []
|
||||
for episode in episodes:
|
||||
title_item = Menu.generate_titleitem(episode)
|
||||
if episode.program_title:
|
||||
title_item.info_dict['title'] = episode.program_title + ' - ' + title_item.title
|
||||
listing.append(title_item)
|
||||
|
||||
|
@ -454,7 +454,7 @@ class ContentApi:
|
||||
|
||||
# Categories regexes
|
||||
regex_articles = re.compile(r'<article[^>]+>(.*?)</article>', re.DOTALL)
|
||||
regex_category = re.compile(r'<h1.*?>(.*?)</h1>(?:.*?<div class=\"visually-hidden\">(.*?)</div>)?', re.DOTALL)
|
||||
regex_category = re.compile(r'<h2.*?>(.*?)</h2>(?:.*?<div class="visually-hidden">(.*?)</div>)?', re.DOTALL)
|
||||
|
||||
categories = []
|
||||
for result in regex_articles.finditer(raw_html):
|
||||
|
@ -75,7 +75,7 @@ class TestApi(unittest.TestCase):
|
||||
|
||||
@unittest.skipUnless(kodiutils.get_setting('username') and kodiutils.get_setting('password'), 'Skipping since we have no credentials.')
|
||||
def test_get_drm_stream(self):
|
||||
resolved_stream = self._api.get_stream_by_uuid('c6c67b09-8068-4121-8030-8708735f1429') # NCIS 18x10
|
||||
resolved_stream = self._api.get_stream_by_uuid('2a17b793-7407-42b2-9851-5487db6d3a6a') # NCIS LA 10x6
|
||||
self.assertIsInstance(resolved_stream, ResolvedStream)
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user