from .common import InfoExtractor
from ..utils import (
+ ExtractorError,
clean_html,
determine_ext,
- ExtractorError,
float_or_none,
int_or_none,
str_or_none,
r'(?s)<ul[^>]+class=["\']error_list[^>]+>(.+?)</ul>', response,
'errors', default=None)
if errors:
- raise ExtractorError('Unable to login: %s' % errors, expected=True)
+ raise ExtractorError(f'Unable to login: {errors}', expected=True)
raise ExtractorError('Unable to log in')
f = {
'url': file_url,
'format_id': label,
- 'filesize': float_or_none(filesize, invscale=1000)
+ 'filesize': float_or_none(filesize, invscale=1000),
}
if label:
mobj = re.match(r'(\d+)p\s*\(([^)]+)\)', label)
if lecture_url:
lecture_url = urljoin(url, lecture_url)
else:
- lecture_url = 'https://app.lecturio.com/#/lecture/c/%s/%s' % (course_id, lecture_id)
+ lecture_url = f'https://app.lecturio.com/#/lecture/c/{course_id}/{lecture_id}'
entries.append(self.url_result(
lecture_url, ie=LecturioIE.ie_key(), video_id=lecture_id))
return self.playlist_result(