ytdl-org/youtube-dl · error · ExtractorError

error

Error message

error

What it means

Error "error" thrown in ytdl-org/youtube-dl.

Source

Thrown at youtube_dl/extractor/odnoklassniki.py:146

        mobj = re.search(
            r'<iframe[^>]+src=(["\'])(?P<url>(?:https?:)?//(?:odnoklassniki|ok)\.ru/videoembed/.+?)\1', webpage)
        if mobj:
            return mobj.group('url')

    def _real_extract(self, url):
        start_time = int_or_none(compat_parse_qs(
            compat_urllib_parse_urlparse(url).query).get('fromTime', [None])[0])

        video_id = self._match_id(url)

        webpage = self._download_webpage(
            'http://ok.ru/video/%s' % video_id, video_id)

        error = self._search_regex(
            r'[^>]+class="vp_video_stub_txt"[^>]*>([^<]+)<',
            webpage, 'error', default=None)
        if error:
            raise ExtractorError(error, expected=True)

        player = self._parse_json(
            unescapeHTML(self._search_regex(
                r'data-options=(?P<quote>["\'])(?P<player>{.+?%s.+?})(?P=quote)' % video_id,
                webpage, 'player', group='player')),
            video_id)

        flashvars = player['flashvars']

        metadata = flashvars.get('metadata')
        if metadata:
            metadata = self._parse_json(metadata, video_id)
        else:
            data = {}
            st_location = flashvars.get('location')
            if st_location:
                data['st.location'] = st_location
            metadata = self._download_json(

View on GitHub (pinned to 956b8c5855)

Solutions

  1. Read the error from the server response; verify the URL and retry.

When it happens

Trigger: Thrown at youtube_dl/extractor/odnoklassniki.py:146 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of ytdl-org/youtube-dl@956b8c5855 (2026-08-14). Data as JSON: /api/errors/3c60ba84db1e6e3b. Report an issue: GitHub.