Skip to content

Commit

Permalink
[tagesschau] Restrict playlist entry regex
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergey M․ committed May 1, 2016
1 parent 854cc54 commit 68bb2fe
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion youtube_dl/extractor/tagesschau.py
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,10 @@ class TagesschauIE(InfoExtractor):
}, {
'url': 'http://www.tagesschau.de/100sekunden/index.html',
'only_matching': True,
}, {
# playlist article with collapsing sections
'url': 'http://www.tagesschau.de/wirtschaft/faq-freihandelszone-eu-usa-101.html',
'only_matching': True,
}]

@classmethod
Expand Down Expand Up @@ -275,7 +279,7 @@ def _real_extract(self, url):
if webpage_type == 'website': # Article
entries = []
for num, (entry_title, media_kind, download_text) in enumerate(re.findall(
r'(?s)<p[^>]+class="infotext"[^>]*>.*?<strong>(.+?)</strong>.*?</p>.*?%s' % DOWNLOAD_REGEX,
r'(?s)<p[^>]+class="infotext"[^>]*>\s*(?:<a[^>]+>)?\s*<strong>(.+?)</strong>.*?</p>.*?%s' % DOWNLOAD_REGEX,
webpage), 1):
entries.append({
'id': '%s-%d' % (display_id, num),
Expand Down

0 comments on commit 68bb2fe

Please sign in to comment.