aboutsummaryrefslogtreecommitdiffstats
path: root/yt_dlp/extractor/sovietscloset.py
diff options
context:
space:
mode:
Diffstat (limited to 'yt_dlp/extractor/sovietscloset.py')
-rw-r--r--yt_dlp/extractor/sovietscloset.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/yt_dlp/extractor/sovietscloset.py b/yt_dlp/extractor/sovietscloset.py
index 64201c88c..7df23759a 100644
--- a/yt_dlp/extractor/sovietscloset.py
+++ b/yt_dlp/extractor/sovietscloset.py
@@ -72,6 +72,7 @@ class SovietsClosetIE(SovietsClosetBaseIE):
'upload_date': '20170413',
'uploader_id': 'SovietWomble',
'uploader_url': 'https://www.twitch.tv/SovietWomble',
+ 'duration': 7007,
'was_live': True,
'availability': 'public',
'series': 'The Witcher',
@@ -96,6 +97,7 @@ class SovietsClosetIE(SovietsClosetBaseIE):
'upload_date': '20160420',
'uploader_id': 'SovietWomble',
'uploader_url': 'https://www.twitch.tv/SovietWomble',
+ 'duration': 8804,
'was_live': True,
'availability': 'public',
'series': 'Arma 3',
@@ -116,9 +118,16 @@ class SovietsClosetIE(SovietsClosetBaseIE):
m3u8_formats = self._extract_m3u8_formats(m3u8_url, video_id, headers=self.MEDIADELIVERY_REFERER)
self._sort_formats(m3u8_formats)
+ if not m3u8_formats:
+ duration = None
+ else:
+ duration = self._extract_m3u8_vod_duration(
+ m3u8_formats[0]['url'], video_id, headers=self.MEDIADELIVERY_REFERER)
+
return {
'formats': m3u8_formats,
'thumbnail': thumbnail_url,
+ 'duration': duration,
}
def _real_extract(self, url):