]> jfr.im git - yt-dlp.git/commitdiff
[ie/youtube] Improve detection of faulty HLS formats (#8646)
authorbashonly <redacted>
Sun, 26 Nov 2023 02:21:29 +0000 (20:21 -0600)
committerGitHub <redacted>
Sun, 26 Nov 2023 02:21:29 +0000 (02:21 +0000)
Closes #7747
Authored by: bashonly

yt_dlp/extractor/youtube.py

index 73fe233effd10a320ad048bd741ed1e738beccf7..449d9d1a565eb6d2d7e99efe2f26159df207b520 100644 (file)
@@ -4562,7 +4562,7 @@ def process_language(container, base_url, lang_code, sub_name, query):
         if upload_date and live_status not in ('is_live', 'post_live', 'is_upcoming'):
             # Newly uploaded videos' HLS formats are potentially problematic and need to be checked
             upload_datetime = datetime_from_str(upload_date).replace(tzinfo=datetime.timezone.utc)
-            if upload_datetime >= datetime_from_str('today-1day'):
+            if upload_datetime >= datetime_from_str('today-2days'):
                 for fmt in info['formats']:
                     if fmt.get('protocol') == 'm3u8_native':
                         fmt['__needs_testing'] = True