From 4cf0d337280726d860ee26200d568ce9c9b2a3b2 Mon Sep 17 00:00:00 2001 From: Kay B <> Date: Mon, 5 Mar 2018 22:43:18 +0100 Subject: [PATCH] [heise] incorporate pull request review --- youtube_dl/extractor/heise.py | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/youtube_dl/extractor/heise.py b/youtube_dl/extractor/heise.py index 8b652d5b0..8f49f52ef 100644 --- a/youtube_dl/extractor/heise.py +++ b/youtube_dl/extractor/heise.py @@ -2,15 +2,14 @@ from __future__ import unicode_literals from .common import InfoExtractor -from .youtube import YoutubeIE from .kaltura import KalturaIE +from .youtube import YoutubeIE from ..utils import ( determine_ext, int_or_none, parse_iso8601, - xpath_text, smuggle_url, - ExtractorError, + xpath_text, ) @@ -55,6 +54,9 @@ class HeiseIE(InfoExtractor): 'ext': 'mp4', 'title': 'ct10 nachgehakt hos restrictor', }, + 'params': { + 'skip_download': True, + }, }, { 'url': 'http://www.heise.de/ct/artikel/c-t-uplink-3-3-Owncloud-Tastaturen-Peilsender-Smartphone-2403911.html', 'only_matching': True, @@ -80,15 +82,13 @@ class HeiseIE(InfoExtractor): if yt_urls: return self.playlist_from_matches(yt_urls, video_id, title, ie=YoutubeIE.ie_key()) - try: - container_id = self._search_regex( - r'
]+data-container="([0-9]+)"', - webpage, 'container ID') + kaltura_url = KalturaIE._extract_url(webpage) + if kaltura_url: + return self.url_result(smuggle_url(kaltura_url, {'source_url': url}), KalturaIE.ie_key()) - except ExtractorError: - kaltura_url = KalturaIE._extract_url(webpage) - if kaltura_url: - return self.url_result(smuggle_url(kaltura_url, {'source_url': url}), KalturaIE.ie_key()) + container_id = self._search_regex( + r'
]+data-container="([0-9]+)"', + webpage, 'container ID') sequenz_id = self._search_regex( r'
]+data-sequenz="([0-9]+)"',