{"record":{"id":"d0cde5b5be956671","repo":"ytdl-org/youtube-dl","slug":"s-returned-error-s-d0cde5","errorCode":null,"errorMessage":"%s returned error: %s","messagePattern":"(.+?) returned error: (.+?)","errorType":"exception","errorClass":"ExtractorError","httpStatus":null,"severity":"error","filePath":"youtube_dl/extractor/francetv.py","lineNumber":101,"sourceCode":"    }, {\n        # france-3 live\n        'url': 'francetv:SIM_France3',\n        'only_matching': True,\n    }]\n\n    def _extract_video(self, video_id, catalogue=None):\n        # Videos are identified by idDiffusion so catalogue part is optional.\n        # However when provided, some extra formats may be returned so we pass\n        # it if available.\n        info = self._download_json(\n            'https://sivideo.webservices.francetelevisions.fr/tools/getInfosOeuvre/v2/',\n            video_id, 'Downloading video JSON', query={\n                'idDiffusion': video_id,\n                'catalogue': catalogue or '',\n            })\n\n        if info.get('status') == 'NOK':\n            raise ExtractorError(\n                '%s returned error: %s' % (self.IE_NAME, info['message']),\n                expected=True)\n        allowed_countries = info['videos'][0].get('geoblocage')\n        if allowed_countries:\n            georestricted = True\n            geo_info = self._download_json(\n                'http://geo.francetv.fr/ws/edgescape.json', video_id,\n                'Downloading geo restriction info')\n            country = geo_info['reponse']['geo_info']['country_code']\n            if country not in allowed_countries:\n                raise ExtractorError(\n                    'The video is not available from your location',\n                    expected=True)\n        else:\n            georestricted = False\n\n        def sign(manifest_url, manifest_id):\n            for host in ('hdfauthftv-a.akamaihd.net', 'hdfauth.francetv.fr'):","sourceCodeStart":83,"sourceCodeEnd":119,"githubUrl":"https://github.com/ytdl-org/youtube-dl/blob/956b8c585591b401a543e409accb163eeaaa1193/youtube_dl/extractor/francetv.py#L83-L119","documentation":"Raised inside FranceTV's _extract_video when the getInfosOeuvre/v2 API responds with status 'NOK'. The API's own 'message' field is surfaced, prefixed with the extractor name, as an expected error. status NOK is France Télévisions' way of saying the idDiffusion is unknown, delisted, or not served by the catalogue.","triggerScenarios":"The POST/GET to sivideo.webservices.francetelevisions.fr returns JSON with status == 'NOK'. Produced by a malformed idDiffusion UUID, a video removed from the francetv catalogue, or passing a catalogue value that does not match the video.","commonSituations":"Deep links from news articles to expired replays; France TV purging replays after rights expire; copy-paste errors in the idDiffusion parameter of pluton or direct francetv URLs.","solutions":["Search the show on france.tv and copy the current URL — replays often move to new ids","Double-check the idDiffusion value for typos/truncation","Accept that French broadcasting rights typically expire replays after 7-30 days; no client fix exists for delisted content","Update youtube-dl/yt-dlp if the API contract changed"],"exampleFix":"# before\nyoutube_dl 'https://www.france.tv/france-2/jt/old-expired-replay.html'\n# ERROR: FranceTV returned error: ...\n\n# after\nyt-dlp 'https://www.france.tv/france-2/jt/current-available-episode.html'","handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"try:\n    info = ydl.extract_info(url)\nexcept ExtractorError as e:\n    if 'FranceTV returned error:' in str(e):\n        mark_expired(url)  # NOK is usually permanent delisting","preventionTips":["Re-resolve francetv URLs from the current site instead of caching old ids","Record France TV content promptly; replay windows are short"],"tags":["francetv","extractor","api-error","expired-content"],"backgroundTag":null,"analyzedSha":"956b8c585591b401a543e409accb163eeaaa1193","analyzedAt":"2026-08-14T18:59:47.863Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}