This commit is contained in:
coletdjnz 2025-04-21 12:17:59 +12:00
parent ae918c4b33
commit 18851f70e0
No known key found for this signature in database
GPG Key ID: 91984263BB39894A

View File

@ -3648,11 +3648,10 @@ class YoutubeIE(YoutubeBaseInfoExtractor):
reason = f'{remove_end(reason.strip(), ".")}. {self._youtube_login_hint}'
elif get_first(playability_statuses, ('errorScreen', 'playerCaptchaViewModel', {dict})):
reason += '. YouTube is requiring a captcha challenge before playback'
elif "This content isn't available, try again later" in reason:
reason = (
f'{remove_end(reason.strip(), ".")}. {"Your account" if self.is_authenticated else "The current session"} has been rate-limited by YouTube for up to an hour. '
'It is recommended to use `-t sleep` to add a delay between downloads to avoid hitting the rate limit. '
'It is recommended to use `-t sleep` to add a delay between video requests to avoid hitting the rate limit. '
'For more information, refer to https://github.com/yt-dlp/yt-dlp/wiki/Extractors#this-content-isnt-available-try-again-later .'
)
self.raise_no_formats(reason, expected=True)