summaryrefslogtreecommitdiffstats
path: root/yt_dlp/extractor/naver.py
diff options
context:
space:
mode:
Diffstat (limited to 'yt_dlp/extractor/naver.py')
-rw-r--r--yt_dlp/extractor/naver.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/yt_dlp/extractor/naver.py b/yt_dlp/extractor/naver.py
index 26400e3..a9f7f46 100644
--- a/yt_dlp/extractor/naver.py
+++ b/yt_dlp/extractor/naver.py
@@ -36,7 +36,7 @@ class NaverBaseIE(InfoExtractor):
type_ = 'automatic_captions' if caption.get('type') == 'auto' else 'subtitles'
lang = caption.get('locale') or join_nonempty('language', 'country', from_dict=caption) or 'und'
if caption.get('type') == 'fan':
- lang += '_fan%d' % next(i for i in itertools.count(1) if f'{lang}_fan{i}' not in ret[type_])
+ lang += '_fan{}'.format(next(i for i in itertools.count(1) if f'{lang}_fan{i}' not in ret[type_]))
ret[type_].setdefault(lang, []).extend({
'url': sub_url,
'name': join_nonempty('label', 'fanName', from_dict=caption, delim=' - '),
@@ -63,7 +63,7 @@ class NaverBaseIE(InfoExtractor):
encoding_option = stream.get('encodingOption', {})
bitrate = stream.get('bitrate', {})
formats.append({
- 'format_id': '%s_%s' % (stream.get('type') or stream_type, dict_get(encoding_option, ('name', 'id'))),
+ 'format_id': '{}_{}'.format(stream.get('type') or stream_type, dict_get(encoding_option, ('name', 'id'))),
'url': stream_url,
'ext': 'mp4',
'width': int_or_none(encoding_option.get('width')),
@@ -261,7 +261,7 @@ class NaverLiveIE(NaverBaseIE):
'thumbnail': ('thumbnailImageUrl', {url_or_none}),
'start_time': (('startTime', 'startDateTime', 'startYmdt'), {parse_iso8601}),
}), get_all=False),
- 'is_live': True
+ 'is_live': True,
}
@@ -286,7 +286,7 @@ class NaverNowIE(NaverBaseIE):
},
'params': {
'noplaylist': True,
- }
+ },
}, {
'url': 'https://now.naver.com/s/now.4759?shareHightlight=26601461#highlight=',
'md5': '9f6118e398aa0f22b2152f554ea7851b',
@@ -311,7 +311,7 @@ class NaverNowIE(NaverBaseIE):
'id': '4759',
'title': '아이키의 떰즈업',
},
- 'playlist_mincount': 101
+ 'playlist_mincount': 101,
}, {
'url': 'https://now.naver.com/s/now.4759?shareReplayId=26331132#replay',
'info_dict': {
@@ -348,7 +348,7 @@ class NaverNowIE(NaverBaseIE):
show_vod_info = self._download_json(
f'{self._API_URL}/vod-shows/now.{show_id}', show_id,
query={'page': page, 'page_size': page_size},
- note=f'Downloading JSON vod list for show {show_id} - page {page}'
+ note=f'Downloading JSON vod list for show {show_id} - page {page}',
)['response']['result']
for v in show_vod_info.get('vod_list') or []:
yield self._extract_replay(show_id, v['id'])