diff options
author | Sergey M․ <dstftw@gmail.com> | 2016-08-21 08:26:45 +0700 |
---|---|---|
committer | Sergey M․ <dstftw@gmail.com> | 2016-08-21 08:28:36 +0700 |
commit | a80944675010617cc0124c57ab597f9d9004c0d9 (patch) | |
tree | a44263d87ceeca570454b0cfcb3044b508a3741b | |
parent | d8f30a7e6606d2300dfffb8fc0aaf8d6a0c79b0f (diff) |
[kaltura] Add subtitles support when entry_id is unknown beforehand (Closes #10279)
-rw-r--r-- | youtube_dl/extractor/kaltura.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/youtube_dl/extractor/kaltura.py b/youtube_dl/extractor/kaltura.py index 66c7b36bc..a8ce6dda2 100644 --- a/youtube_dl/extractor/kaltura.py +++ b/youtube_dl/extractor/kaltura.py @@ -196,6 +196,17 @@ class KalturaIE(InfoExtractor): reference_id)['entryResult'] info, flavor_assets = entry_data['meta'], entry_data['contextData']['flavorAssets'] entry_id = info['id'] + # Unfortunately, data returned in kalturaIframePackageData lacks + # captions so we will try requesting the complete data using + # regular approach since we now know the entry_id + try: + _, info, flavor_assets, captions = self._get_video_info( + entry_id, partner_id) + except ExtractorError: + # Regular scenario failed but we already have everything + # extracted apart from captions and can process at least + # with this + pass else: raise ExtractorError('Invalid URL', expected=True) ks = params.get('flashvars[ks]', [None])[0] |