Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[youtube] Age gated video fail with 404 error #29333

Closed
6 tasks done
someziggyman opened this issue Jun 18, 2021 · 8 comments
Closed
6 tasks done

[youtube] Age gated video fail with 404 error #29333

someziggyman opened this issue Jun 18, 2021 · 8 comments

Comments

@someziggyman
Copy link

someziggyman commented Jun 18, 2021

Checklist

  • I'm reporting a broken site support issue
  • I've verified that I'm running youtube-dl version 2021.06.06
  • I've checked that all provided URLs are alive and playable in a browser
  • I've checked that all URLs and arguments with special characters are properly quoted or escaped
  • I've searched the bugtracker for similar bug reports including closed ones
  • I've read bugs section in FAQ

Verbose log

youtube-dl -v -F https://www.youtube.com/watch?v=XgnwCQzjau8
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: [u'-v', u'-F', u'https://www.youtube.com/watch?v=XgnwCQzjau8']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2021.06.06
[debug] Python version 2.7.16 (CPython) - Darwin-20.5.0-x86_64-i386-64bit
[debug] exe versions: none
[debug] Proxy map: {}
[youtube] XgnwCQzjau8: Downloading webpage
[youtube] XgnwCQzjau8: Refetching age-gated info webpage
WARNING: unable to download video info webpage: HTTP Error 404: Not Found
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py", line 174, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/usr/local/bin/youtube-dl/__main__.py", line 19, in <module>
  File "/usr/local/bin/youtube-dl/youtube_dl/__init__.py", line 475, in main
  File "/usr/local/bin/youtube-dl/youtube_dl/__init__.py", line 465, in _real_main
  File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 2069, in download
  File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 808, in extract_info
  File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 815, in wrapper
  File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 836, in __extract_info
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 534, in extract
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/youtube.py", line 1503, in _real_extract
  File "/usr/local/bin/youtube-dl/youtube_dl/compat.py", line 2644, in compat_parse_qs
  File "/usr/local/bin/youtube-dl/youtube_dl/compat.py", line 2614, in _parse_qsl
AttributeError: 'bool' object has no attribute 'split'

Description

Test link:
https://www.youtube.com/watch?v=XgnwCQzjau8

maybe adding these params:
https://stackoverflow.com/questions/67615278/get-video-info-youtube-endpoint-suddenly-returning-404-not-found/67629882#67629882
here:
24297a4
helps or at least gives a hint.

@someziggyman
Copy link
Author

Ok ,so I added params below:
'html5': '1',
'c': 'TVHTML5',
'cver': '6.20180913',

Here: 24297a4
and the issue seems to be gone... Not sire how solid of a solution that is..

@pukkandan
Copy link
Contributor

pukkandan commented Jun 18, 2021

Ok ,so I added params below:
'html5': '1',
'c': 'TVHTML5',
'cver': '6.20180913',

Here: 24297a4
and the issue seems to be gone... Not sire how solid of a solution that is..

This seems to work for now. But it will also break eventually

@E-Mans-Application
Copy link

Thank you very much!
I have been looking for a solution for hours. How did you find it so fast?

YouTube really seems committed to blocking any third-party tool that alters its restrictions...

@Lesmiscore
Copy link
Contributor

Ok ,so I added params below:
'html5': '1',
'c': 'TVHTML5',
'cver': '6.20180913',

Here: 24297a4
and the issue seems to be gone... Not sire how solid of a solution that is..

lol, I found out that this is mimicking TV client like this
Screenshot from 2021-06-19 12-45-41
Screenshot from 2021-06-19 12-45-44

UA: Mozilla/5.0 (Linux; U; Android 4.1.1; nl-nl; POV_TV-HDMI-200BT Build/JRO03H) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Safari/534.30
(second image is saying "Log in to Google account" and "To watch this video, age verification is required")

@rjdg14
Copy link

rjdg14 commented Jun 21, 2021

Ok ,so I added params below:
'html5': '1',
'c': 'TVHTML5',
'cver': '6.20180913',
Here: 24297a4
and the issue seems to be gone... Not sire how solid of a solution that is..

lol, I found out that this is mimicking TV client like this
Screenshot from 2021-06-19 12-45-41
Screenshot from 2021-06-19 12-45-44

UA: Mozilla/5.0 (Linux; U; Android 4.1.1; nl-nl; POV_TV-HDMI-200BT Build/JRO03H) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Safari/534.30
(second image is saying "Log in to Google account" and "To watch this video, age verification is required")

Is that octopus image exclusive to the Japanese version of YouTube, considering that the Japanese like to give everything a mascot? I haven't seen it on any European or American versions of the site.

@Lesmiscore
Copy link
Contributor

@rjdg14

Is that octopus image exclusive to the Japanese version of YouTube, considering that the Japanese like to give everything a mascot? I haven't seen it on any European or American versions of the site.

I don't know. Check it yourself if you wish.

@ezhikus
Copy link

ezhikus commented Jun 22, 2021

It doesn't work anymore:
image

@Lesmiscore
Copy link
Contributor

Lesmiscore commented Jul 13, 2021

@89z No, it's recently deleted. It existed as of @ezhikus's comment.

gaming-hacker added a commit to gaming-hacker/youtube-dl that referenced this issue Sep 3, 2021
* commit '188b7b108e1cd287580bee5dba8075e669c29a10': (192 commits)
  Avoid skipping ID when unlisted_hash is numeric
  [peertube] only call description endpoint if necessary (ytdl-org#29383)
  [periscope] pass referer to HLS requests(closes ytdl-org#29419)
  [liveleak] Remove extractor (closes ytdl-org#17625, closes ytdl-org#24222) (ytdl-org#29331)
  [pornhub] Add support for pornhubthbh7ap3u.onion
  [pornhub] Detect geo restriction
  [pornhub] Dismiss tbr extracted from download URLs (closes ytdl-org#28927)
  [curiositystream:collection] Extend _VALID_URL (closes ytdl-org#26326, closes ytdl-org#29117)
  [youtube] Make get_video_info processing more robust (closes ytdl-org#29333)
  [youtube] Workaround for get_video_info request (refs ytdl-org#29333)
  [bilibili] Strip uploader name (ytdl-org#29202)
  [youtube] Update invidious instance list (ytdl-org#29281)
  [umg:de] Update GraphQL API URL (ytdl-org#29304)
  [nrk] Switch psapi URL to https (closes ytdl-org#29344)
  [postprocessor/ffmpeg] Show ffmpeg output on error (refs ytdl-org#22680) (ytdl-org#29336)
  [egghead] Add support for app.egghead.io (closes ytdl-org#28404) (ytdl-org#29303)
  [appleconnect] Fix extraction (ytdl-org#29208)
  [orf:tvthek] Add support for MPD formats (closes ytdl-org#28672) (ytdl-org#29236)
  [README.md] Update MSVC 2010 redist URL (closes ytdl-org#29222)
  release 2021.06.06
  ...

# Conflicts:
#	youtube_dl/extractor/generic.py
@Lesmiscore Lesmiscore mentioned this issue Feb 20, 2022
14 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants