{"record":{"id":"48f91627ef075c6a","repo":"ytdl-org/youtube-dl","slug":"this-video-is-drm-protected-48f916","errorCode":null,"errorMessage":"This video is DRM protected.","messagePattern":"This video is DRM protected\\.","errorType":"exception","errorClass":"ExtractorError","httpStatus":null,"severity":"error","filePath":"youtube_dl/extractor/wat.py","lineNumber":90,"sourceCode":"\n        def extract_formats(manifest_urls):\n            for f, f_url in manifest_urls.items():\n                if not f_url:\n                    continue\n                if f in ('dash', 'mpd'):\n                    formats.extend(self._extract_mpd_formats(\n                        f_url.replace('://das-q1.tf1.fr/', '://das-q1-ssl.tf1.fr/'),\n                        video_id, mpd_id='dash', fatal=False))\n                elif f == 'hls':\n                    formats.extend(self._extract_m3u8_formats(\n                        f_url, video_id, 'mp4',\n                        'm3u8_native', m3u8_id='hls', fatal=False))\n\n        delivery = video_data.get('delivery') or {}\n        extract_formats({delivery.get('format'): delivery.get('url')})\n        if not formats:\n            if delivery.get('drm'):\n                raise ExtractorError('This video is DRM protected.', expected=True)\n            manifest_urls = self._download_json(\n                'http://www.wat.tv/get/webhtml/' + video_id, video_id, fatal=False)\n            if manifest_urls:\n                extract_formats(manifest_urls)\n\n        self._sort_formats(formats)\n\n        return {\n            'id': video_id,\n            'title': title,\n            'thumbnail': video_info.get('preview'),\n            'upload_date': unified_strdate(try_get(\n                video_data, lambda x: x['mediametrie']['chapters'][0]['estatS4'])),\n            'duration': int_or_none(video_info.get('duration')),\n            'formats': formats,\n        }\n","sourceCodeStart":72,"sourceCodeEnd":107,"githubUrl":"https://github.com/ytdl-org/youtube-dl/blob/956b8c585591b401a543e409accb163eeaaa1193/youtube_dl/extractor/wat.py#L72-L107","documentation":"Raised by the Wat extractor when no formats were extracted from the delivery field AND the delivery object has drm truthy. It is the fallback path after extract_formats found nothing usable, indicating the stream exists only in a DRM-protected delivery.","triggerScenarios":"mediainfo.tf1.fr returns a delivery whose format/url produce no formats (empty url, or MPD/HLS extraction all failed with fatal=False) and delivery['drm'] is set; the fallback get/webhtml lookup then never runs.","commonSituations":"Premium TF1/wat.tv content only served under PlayReady/Widevine; partial delivery entries where the plain-media URL is absent because rights require DRM.","solutions":["Use the official TF1/MYTF1 player for DRM content — youtube-dl cannot decrypt it.","Check whether a non-DRM delivery exists for the same video (e.g. free replay vs premium version).","If you believe the video is not DRM-protected, the manifest extraction may have silently failed (fatal=False) — report upstream with verbose output (-v)."],"exampleFix":null,"handlingStrategy":"validation","validationCode":"delivery = video_data.get('delivery') or {}\nif not delivery.get('url') and delivery.get('drm'):\n    raise SystemExit(f'{video_id}: DRM-only delivery, skipping')","typeGuard":"def is_drm_only_delivery(video_data: dict) -> bool:\n    delivery = video_data.get('delivery') or {}\n    return bool(delivery.get('drm')) and not delivery.get('url')","tryCatchPattern":"try:\n    info = ydl.extract_info(url)\nexcept ExtractorError as e:\n    if 'DRM protected' in str(e):\n        skip_drm(url)\n    else:\n        raise","preventionTips":["Prefer free/replay TF1 content over premium streams in automated queues.","Inspect the mediainfo JSON's delivery.drm flag before extraction in custom clients.","Run with -v to distinguish silent format-extraction failures from real DRM."],"tags":["drm","geo-restriction","extractor","wat","tf1"],"backgroundTag":null,"analyzedSha":"956b8c585591b401a543e409accb163eeaaa1193","analyzedAt":"2026-08-14T18:59:47.863Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}