votes up 2

Unable to recognize tab page

Package:
Exception Class:
ExtractorError

Raise code

        if video_id:
            return self.url_result(video_id, ie=YoutubeIE.ie_key(), video_id=video_id)
        # Capture and output alerts
        alert = self._extract_alert(data)
        if alert:
            raise ExtractorError(alert, expected=True)
        # Failed to recognize
        raise ExtractorError('Unable to recognize tab page')


class YoutubePlaylistIE(InfoExtractor):
    IE_DESC = 'YouTube.com playlists'
    _VALID_URL = r'''(?x)(?:
                        (?:https?://)?
                        (?:\w+\.)? '''

Comment explaining raise

Failed to recognize

Ways to fix

votes up 1 votes down

Installing package:

pip install youtube-dl

Error code:

youtube-dl https://www.youtube.com/results?search_query=gta

youtube-dl package allows users to download videos or playlists from youtube. But when they want to download videos from the searched results, they will face errors. Instead of using search URL, they can use ytsearchall::gta.

youtube-dl ytsearchall::gta

In this code, it searches GTA on youtube and downloads all videos.

You can write ytsearch::gta to search and download 1 video.

Jun 10, 2021 nurlan.taghi answer
nurlan.taghi 6.3k

Add a possible fix

Please authorize to post fix