[downloader] Do not use aria2c for non-native m3u8

Closes #2718
This commit is contained in:
pukkandan 2022-02-11 12:09:03 +05:30
parent 3856407a86
commit 079a7cfc71
No known key found for this signature in database
GPG Key ID: 7EEE9E1E817D0A39
4 changed files with 4 additions and 5 deletions

View File

@ -117,7 +117,7 @@ def _get_suitable_downloader(info_dict, protocol, params, default):
return FFmpegFD
elif (external_downloader or '').lower() == 'native':
return HlsFD
elif get_suitable_downloader(
elif protocol == 'm3u8_native' and get_suitable_downloader(
info_dict, params, None, protocol='m3u8_frag_urls', to_stdout=info_dict['to_stdout']):
return HlsFD
elif params.get('hls_prefer_native') is True:

View File

@ -3108,7 +3108,7 @@ def _parse_ism_formats_and_subtitles(self, ism_doc, ism_url, ism_id=None):
})
return formats, subtitles
def _parse_html5_media_entries(self, base_url, webpage, video_id, m3u8_id=None, m3u8_entry_protocol='m3u8', mpd_id=None, preference=None, quality=None):
def _parse_html5_media_entries(self, base_url, webpage, video_id, m3u8_id=None, m3u8_entry_protocol='m3u8_native', mpd_id=None, preference=None, quality=None):
def absolute_url(item_url):
return urljoin(base_url, item_url)

View File

@ -42,8 +42,7 @@ def _extract_movie(self, webpage, video_id, name, is_live):
if not m3u8_url:
continue
formats.extend(self._extract_m3u8_formats(
m3u8_url, video_id, ext='mp4', entry_protocol='m3u8',
m3u8_id='hls-%s' % name, live=True))
m3u8_url, video_id, ext='mp4', live=is_live, m3u8_id='hls-%s' % name))
self._sort_formats(formats)

View File

@ -688,7 +688,7 @@ def _real_extract(self, url):
'artist': performer,
'track': title,
'ext': 'mp4',
'protocol': 'm3u8',
'protocol': 'm3u8_native',
})
for video in re.finditer(