1
0
mirror of https://github.com/yt-dlp/yt-dlp synced 2025-12-17 06:35:42 +07:00

Update to ytdl-commit-ed5c44e7

[compat] Replace deficient ChainMap class in Py3.3 and earlier
ed5c44e7b7
This commit is contained in:
pukkandan
2022-09-01 16:23:18 +05:30
parent 05deb747bb
commit 1ac7f46184
4 changed files with 92 additions and 44 deletions

View File

@@ -2528,9 +2528,6 @@ def sanitize_numeric_fields(info):
'--live-from-start is passed, but there are no formats that can be downloaded from the start. '
'If you want to download from the current time, use --no-live-from-start'))
if not formats:
self.raise_no_formats(info_dict)
def is_wellformed(f):
url = f.get('url')
if not url:
@@ -2543,7 +2540,10 @@ def is_wellformed(f):
return True
# Filter out malformed formats for better extraction robustness
formats = list(filter(is_wellformed, formats))
formats = list(filter(is_wellformed, formats or []))
if not formats:
self.raise_no_formats(info_dict)
formats_dict = {}