diff --git a/yt_dlp/extractor/youtube/_base.py b/yt_dlp/extractor/youtube/_base.py index 0a9b510c7d..8f2cb7f344 100644 --- a/yt_dlp/extractor/youtube/_base.py +++ b/yt_dlp/extractor/youtube/_base.py @@ -261,9 +261,8 @@ class SubsPoTokenPolicy(BasePoTokenPolicy): not_required_with_player_token=True, ), # HLS Livestreams require POT 30 seconds in - # TODO: Rolling out StreamingProtocol.HLS: GvsPoTokenPolicy( - required=False, + required=True, recommended=True, not_required_with_player_token=True, ), diff --git a/yt_dlp/extractor/youtube/_video.py b/yt_dlp/extractor/youtube/_video.py index fc1f087ace..053dca5ed7 100644 --- a/yt_dlp/extractor/youtube/_video.py +++ b/yt_dlp/extractor/youtube/_video.py @@ -256,7 +256,7 @@ class YoutubeIE(YoutubeBaseInfoExtractor): '401': {'ext': 'mp4', 'height': 2160, 'format_note': 'DASH video', 'vcodec': 'av01.0.12M.08'}, } _SUBTITLE_FORMATS = ('json3', 'srv1', 'srv2', 'srv3', 'ttml', 'srt', 'vtt') - _DEFAULT_CLIENTS = ('tv', 'ios', 'web') + _DEFAULT_CLIENTS = ('tv', 'web') _DEFAULT_AUTHED_CLIENTS = ('tv', 'web') # Premium does not require POT (except for subtitles) _DEFAULT_PREMIUM_CLIENTS = ('tv', 'web') @@ -3291,11 +3291,9 @@ def _report_pot_format_skipped(self, video_id, client_name, proto): f'{video_id}: {client_name} client {proto} formats require a GVS PO Token which was not provided. ' 'They will be skipped as they may yield HTTP Error 403. ' f'You can manually pass a GVS PO Token for this client with --extractor-args "youtube:po_token={client_name}.gvs+XXX". ' - f'For more information, refer to {PO_TOKEN_GUIDE_URL} . ' - 'To enable these broken formats anyway, pass --extractor-args "youtube:formats=missing_pot"') + f'For more information, refer to {PO_TOKEN_GUIDE_URL} . ') # Only raise a warning for non-default clients, to not confuse users. - # iOS HLS formats still work without PO Token, so we don't need to warn about them. if client_name in (*self._DEFAULT_CLIENTS, *self._DEFAULT_AUTHED_CLIENTS): self.write_debug(msg, only_once=True) else: @@ -3584,11 +3582,6 @@ def process_manifest_format(f, proto, client_name, itag, missing_pot): f['format_note'] = join_nonempty(f.get('format_note'), 'MISSING POT', delim=' ') f['source_preference'] -= 20 - # XXX: Check if IOS HLS formats are affected by PO token enforcement; temporary - # See https://github.com/yt-dlp/yt-dlp/issues/13511 - if proto == 'hls' and client_name == 'ios': - f['__needs_testing'] = True - itags[itag].add(key) if itag and all_formats: @@ -4373,7 +4366,6 @@ def process_language(container, base_url, lang_code, sub_name, client_name, quer 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 - # XXX: This is redundant for as long as we are already checking all IOS HLS formats upload_datetime = datetime_from_str(upload_date).replace(tzinfo=dt.timezone.utc) if upload_datetime >= datetime_from_str('today-2days'): for fmt in info['formats']: