{"record":{"id":"c07d0b9ae6e0bb66","repo":"ytdl-org/youtube-dl","slug":"cannot-find-video-formats","errorCode":null,"errorMessage":"Cannot find video formats","messagePattern":"Cannot find video formats","errorType":"exception","errorClass":"ExtractorError","httpStatus":null,"severity":"error","filePath":"youtube_dl/extractor/facebook.py","lineNumber":632,"sourceCode":"                continue\n            for quality in ('sd', 'hd'):\n                for src_type in ('src', 'src_no_ratelimit'):\n                    src = f[0].get('%s_%s' % (quality, src_type))\n                    if src:\n                        preference = -10 if format_id == 'progressive' else 0\n                        if quality == 'hd':\n                            preference += 5\n                        formats.append({\n                            'format_id': '%s_%s_%s' % (format_id, quality, src_type),\n                            'url': src,\n                            'preference': preference,\n                        })\n            extract_dash_manifest(f[0], formats)\n            subtitles_src = f[0].get('subtitles_src')\n            if subtitles_src:\n                subtitles.setdefault('en', []).append({'url': subtitles_src})\n        if not formats:\n            raise ExtractorError('Cannot find video formats')\n\n        process_formats(formats)\n\n        video_title = self._html_search_regex(\n            r'<h2\\s+[^>]*class=\"uiHeaderTitle\"[^>]*>([^<]*)</h2>', webpage,\n            'title', default=None)\n        if not video_title:\n            video_title = self._html_search_regex(\n                r'(?s)<span class=\"fbPhotosPhotoCaption\".*?id=\"fbPhotoPageCaption\"><span class=\"hasCaption\">(.*?)</span>',\n                webpage, 'alternative title', default=None)\n        if not video_title:\n            video_title = self._html_search_meta(\n                'description', webpage, 'title', default=None)\n        if video_title:\n            video_title = limit_length(video_title, 80)\n        else:\n            video_title = 'Facebook video #%s' % video_id\n        uploader = clean_html(get_element_by_id(","sourceCodeStart":614,"sourceCodeEnd":650,"githubUrl":"https://github.com/ytdl-org/youtube-dl/blob/956b8c585591b401a543e409accb163eeaaa1193/youtube_dl/extractor/facebook.py#L614-L650","documentation":"Raised by the Facebook extractor when video metadata was found but no playable format could be extracted from it: the formats list built from progressive (video source) entries and DASH manifests is empty. This happens when the metadata contains only formats the extractor cannot represent (e.g. encrypted or stream-only sources) or when the format fields were renamed. It is not marked expected, so it frequently signals an outdated extractor.","triggerScenarios":"After parsing video_data (single or from the tahoe/HTML paths), every candidate source is skipped because 'src' keys are missing, so 'if not formats: raise ExtractorError(\"Cannot find video formats\")' fires. Seen with live streams whose metadata has no progressive src, DRM-wrapped sources, or format schema changes by Facebook.","commonSituations":"Attempting a Facebook Live URL mid-stream or post-stream with an old youtube-dl; extracting HD-only videos after a markup change; running youtube-dl versions from a different era than Facebook's current player payload.","solutions":["Update youtube-dl or switch to yt-dlp, whose Facebook format extraction is actively maintained","Retry after the live stream ends and is converted to a normal VOD","Pass login cookies so Facebook returns the full set of sources","If reproducible on the latest version, file an extractor issue including -v output"],"exampleFix":"# before\nyoutube_dl 'https://www.facebook.com/somepage/videos/987654321'\n# ERROR: Cannot find video formats\n\n# after\npip install -U yt-dlp\nyt-dlp 'https://www.facebook.com/somepage/videos/987654321'","handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"try:\n    info = ydl.extract_info(url)\nexcept ExtractorError as e:\n    if 'Cannot find video formats' in str(e):\n        skip_or_retry_after_stream_ends(url)","preventionTips":["Use yt-dlp for Facebook live/VOD extraction","Do not attempt Facebook Live URLs until the stream has ended","Update the tool before bulk runs"],"tags":["facebook","extractor","formats","out-of-date"],"backgroundTag":null,"analyzedSha":"956b8c585591b401a543e409accb163eeaaa1193","analyzedAt":"2026-08-14T18:59:47.863Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}