]> git.bitcoin.ninja Git - youtube-dl/commitdiff
[abc:iview] Extract more series metadata
authorSergey M․ <dstftw@gmail.com>
Tue, 12 Jun 2018 13:25:50 +0000 (20:25 +0700)
committerSergey M․ <dstftw@gmail.com>
Tue, 12 Jun 2018 13:25:50 +0000 (20:25 +0700)
youtube_dl/extractor/abc.py

index 266d76481b2a64837dfb46575831179554754aed..4ac323bf6de6d17016c2425c133aad460072cadd 100644 (file)
@@ -181,6 +181,11 @@ class ABCIViewIE(InfoExtractor):
             'timestamp': parse_iso8601(video_params.get('pubDate'), ' '),
             'series': unescapeHTML(video_params.get('seriesTitle')),
             'series_id': video_params.get('seriesHouseNumber') or video_id[:7],
+            'season_number': int_or_none(self._search_regex(
+                r'\bSeries\s+(\d+)\b', title, 'season number', default=None)),
+            'episode_number': int_or_none(self._search_regex(
+                r'\bEp\s+(\d+)\b', title, 'episode number', default=None)),
+            'episode_id': house_number,
             'uploader_id': video_params.get('channel'),
             'formats': formats,
             'subtitles': subtitles,