diff --git a/addon.xml b/addon.xml index 59d30aa24..1fb75467d 100644 --- a/addon.xml +++ b/addon.xml @@ -1,5 +1,5 @@ - + diff --git a/changelog.txt b/changelog.txt index eda86c0ec..2595977a9 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,4 +1,4 @@ -## v7.1.0 +## v7.1.0.1 ### Fixed - Fix logging/retry of sqlite3.OperationalError - Fix trying to use ISA for progressive live streams @@ -13,6 +13,9 @@ - Fix new resume details not being saved in plugin local playback history #904 - Fix default thumbnails not being updated if available - Fix login to personal project only #910 +- Fix regression with not using content type when routing after f239764 #922 +- Partially revert eb0f81c to avoid merge error in unofficial version #924 +- Only attempt to import InputStream Helper if necessary #923 ### Changed - Update multiple busy dialog crash workaround #891 diff --git a/resources/lib/youtube_plugin/kodion/abstract_provider.py b/resources/lib/youtube_plugin/kodion/abstract_provider.py index 0ed725e62..eef5ae9c9 100644 --- a/resources/lib/youtube_plugin/kodion/abstract_provider.py +++ b/resources/lib/youtube_plugin/kodion/abstract_provider.py @@ -117,6 +117,9 @@ def wrapper(method): return wrapper def run_wizard(self, context): + # ui local variable used for ui.get_view_manager() in unofficial version + ui = context.get_ui() + context.wakeup( CHECK_SETTINGS, timeout=5, @@ -129,7 +132,7 @@ def run_wizard(self, context): steps = len(wizard_steps) try: - if wizard_steps and context.get_ui().on_yes_no_input( + if wizard_steps and ui.on_yes_no_input( context.localize('setup_wizard'), (context.localize('setup_wizard.prompt') % context.localize('setup_wizard.prompt.settings')) diff --git a/resources/lib/youtube_plugin/kodion/plugin/xbmc/xbmc_plugin.py b/resources/lib/youtube_plugin/kodion/plugin/xbmc/xbmc_plugin.py index 15dcd3aba..971b2d814 100644 --- a/resources/lib/youtube_plugin/kodion/plugin/xbmc/xbmc_plugin.py +++ b/resources/lib/youtube_plugin/kodion/plugin/xbmc/xbmc_plugin.py @@ -259,8 +259,9 @@ def run(self, provider, context, focused=None): cache_to_disc = options.get(provider.RESULT_CACHE_TO_DISC, True) update_listing = options.get(provider.RESULT_UPDATE_LISTING, False) else: - ui.clear_property(CONTENT_TYPE) succeeded = bool(result) + if not succeeded: + ui.clear_property(CONTENT_TYPE) cache_to_disc = False update_listing = True diff --git a/resources/lib/youtube_plugin/youtube/helper/utils.py b/resources/lib/youtube_plugin/youtube/helper/utils.py index 678ab3698..d44ff78a2 100644 --- a/resources/lib/youtube_plugin/youtube/helper/utils.py +++ b/resources/lib/youtube_plugin/youtube/helper/utils.py @@ -23,11 +23,6 @@ ) -try: - from inputstreamhelper import Helper as ISHelper -except ImportError: - ISHelper = None - __RE_PLAYLIST = re.compile( r'^(/channel/(?P[^/]+))/playlist/(?P[^/]+)/?$' ) @@ -866,17 +861,23 @@ def update_play_info(provider, context, video_id, media_item, video_stream): if use_isa: license_info = video_stream.get('license_info', {}) - license_proxy = license_info.get('proxy', '') - license_url = license_info.get('url', '') - license_token = license_info.get('token', '') + license_proxy = license_info.get('proxy') + license_url = license_info.get('url') + license_token = license_info.get('token') + + if license_proxy and license_url and license_token: + try: + from inputstreamhelper import Helper - if ISHelper and license_proxy and license_url and license_token: - ISHelper('mpd' if media_item.use_mpd() else 'hls', - drm='com.widevine.alpha').check_inputstream() + is_helper = Helper('mpd' if media_item.use_mpd() else 'hls', + drm='com.widevine.alpha') + except ImportError: + is_helper = None - media_item.set_license_key(license_proxy) - ui.set_property(LICENSE_URL, license_url) - ui.set_property(LICENSE_TOKEN, license_token) + if is_helper and is_helper.check_inputstream(): + media_item.set_license_key(license_proxy) + ui.set_property(LICENSE_URL, license_url) + ui.set_property(LICENSE_TOKEN, license_token) def update_fanarts(provider, context, channel_items_dict, data=None):