-# coding: utf-8
-from __future__ import unicode_literals
-
-
from .common import InfoExtractor
from ..utils import ExtractorError
'categories': list,
},
'skip': 'Blocked outside of Israel',
- }
+ },
]
def _real_extract(self, url):
video_id = self._html_search_regex(r'clipId=([\w-]+)', webpage, 'video id')
metadata = self._download_xml(
- 'http://sport5-metadata-rr-d.nsacdn.com/vod/vod/%s/HDS/metadata.xml' % video_id,
+ f'http://sport5-metadata-rr-d.nsacdn.com/vod/vod/{video_id}/HDS/metadata.xml',
video_id)
error = metadata.find('./Error')
if error is not None:
raise ExtractorError(
- '%s returned error: %s - %s' % (
+ '{} returned error: {} - {}'.format(
self.IE_NAME,
error.find('./Name').text,
error.find('./Description').text),
'width': int(fmt.get('width')),
'height': int(fmt.get('height')),
} for fmt in metadata.findall('./PlaybackLinks/FileURL')]
- self._sort_formats(formats)
return {
'id': video_id,