question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

xvideos resulting in 404

See original GitHub issue

Checklist

  • I’m reporting a broken site support
  • 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 issues including closed ones

Verbose log

[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-v', 'https://www.xvideos.com/video64651723/18yo_youtuber_gets_horny_watching_hentai_during_the_stream_and_masturbates_-_emma_fiore']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] youtube-dl version 2021.06.06
[debug] Python version 3.9.2 (CPython) - Linux-5.10.0-6parrot1-amd64-x86_64-with-glibc2.31
[debug] exe versions: ffmpeg 4.3.2-0, ffprobe 4.3.2-0, phantomjs 2.1.1, rtmpdump 2.4
[debug] Proxy map: {}
[XVideos] 64651723: Downloading webpage
ERROR: Unable to download webpage: HTTP Error 404: Not Found (caused by <HTTPError 404: 'Not Found'>); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
  File "/usr/lib/python3/dist-packages/youtube_dl/extractor/common.py", line 634, in _request_webpage
    return self._downloader.urlopen(url_or_request)
  File "/usr/lib/python3/dist-packages/youtube_dl/YoutubeDL.py", line 2288, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "/usr/lib/python3.9/urllib/request.py", line 523, in open
    response = meth(req, response)
  File "/usr/lib/python3.9/urllib/request.py", line 632, in http_response
    response = self.parent.error(
  File "/usr/lib/python3.9/urllib/request.py", line 561, in error
    return self._call_chain(*args)
  File "/usr/lib/python3.9/urllib/request.py", line 494, in _call_chain
    result = func(*args)
  File "/usr/lib/python3.9/urllib/request.py", line 641, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)

Description

Tried downloading several different videos from this site over the course of the past week. All have resulted in 404, whereas previously, videos have been able to be downloaded from this site without error in the recent past. Confirmed that URLs used are able to be viewed in a web browser without error. Verified youtube-dl version. Updated to 2021.06.06. Tried again with no change in results. Searched github issues for similar posts. Found only one that was locked as off topic. I do not understand the nature of that particular topic being locked, so if I am making a mistake by posting this issue, please forgive me. The site is listed in the sites supported by youtube-dl at https://github.com/ytdl-org/youtube-dl/blob/master/docs/supportedsites.md

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:2
  • Comments:12 (5 by maintainers)

github_iconTop GitHub Comments

15reactions
dirkfcommented, Nov 26, 2021

The site no longer understands URLs ending in video{video_id}/. Apparently we just have to add some final component:

--- old/youtube-dl/youtube_dl/extractor/xvideos.py
+++ new/youtube-dl/youtube_dl/extractor/xvideos.py
@@ -82,7 +82,7 @@
         video_id = self._match_id(url)
 
         webpage = self._download_webpage(
-            'https://www.xvideos.com/video%s/' % video_id, video_id)
+            'https://www.xvideos.com/video%s/0' % video_id, video_id)
 
         mobj = re.search(r'<h1 class="inlineError">(.+?)</h1>', webpage)
         if mobj:

[Update] Patch instructions for Unix-like systems not using a single file self-extracting archive (ie ls -l $(which youtube-dl) shows a file <1kB, not >1.5MB):

  • find the installation directory where the file YoutubeDL.py is;

  • save the patch from this post (from the first --- including the last :), say 30271.patch;

  • become admin (eg, sudo -i);

  • then:

cat 30271.patch | (cd /path/to/ytdl/installation && patch -p 2)
youtube-dl --version

Very careful patchers whose patch supports these options may like to run the command adding --dry-run --verbose first to verify the patch.

7reactions
chrecinoscommented, Jan 2, 2022

recin

Fix in macOS installed with Homebrew

Edit the file

/usr/local/Cellar/youtube-dl/2021.12.17/libexec/lib/python3.10/site-packages/youtube_dl/extractor

Find the line with the following code:

            'https://www.xvideos.com/video%s/' % video_id, video_id)

Replace it with this

            'https://www.xvideos.com/video%s/0' % video_id, video_id)
Read more comments on GitHub >

github_iconTop Results From Across the Web

'404 girls' Search - XVIDEOS.COM
26348 404 girls FREE videos found on XVIDEOS for this search.
Read more >
'Black 404 girls african' Search - XVIDEOS.COM
55673 Black 404 girls african FREE videos found on XVIDEOS for this search. ... Black 404 girls african (55,673 results) Report. Sort by...
Read more >
'404 sluts' Search - XVIDEOS.COM
5496 404 sluts FREE videos found on XVIDEOS for this search. ... 404 sluts (5,496 results) Report. Sort by : Relevance.
Read more >
Youtube-DL started throwing a 404 when downloading twitch ...
Youtube-DL started throwing a 404 when downloading twitch clips ... Downloading JSON metadata ERROR: unable to download video data: HTTP Error 404:.
Read more >
'404 girl xxx teen' Search - XVIDEOS.COM
109537 404 girl xxx teen FREE videos found on XVIDEOS for this search. ... 404 girl xxx teen (109,537 results) ... 18 min404...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found