ytdl-org / youtube-dl

Command-line program to download videos from YouTube.com and other video sites
http://ytdl-org.github.io/youtube-dl/
The Unlicense
132.76k stars 10.07k forks source link

Facebook video not downloading (for recordings from live-video) #7917

Closed Shudouken closed 8 years ago

Shudouken commented 8 years ago

I noticed that whenever a video on facebook was uploaded via live broadcast like this one it won't play even if the broadcast is over. Logging into facebook through youtube-dl didn't solve the issue.

$ youtube-dl --verbose "https://www.facebook.com/myspass/videos/10153760344058119/"
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['--verbose', 'https://www.facebook.com/myspass/videos/10153760344058119/']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2015.12.18
[debug] Python version 3.5.1 - Linux-4.2.5-1-ARCH-x86_64-with-arch
[debug] exe versions: ffmpeg 2.8.3, ffprobe 2.8.3, rtmpdump 2.4
[debug] Proxy map: {}
[facebook] 10153760344058119: Downloading webpage
ERROR: Unable to download webpage: HTTP Error 500: Internal Server Error (caused by <HTTPError 500: 'Internal Server Error'>); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type  youtube-dl -U  to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 329, in _request_webpage
    return self._downloader.urlopen(url_or_request)
  File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1884, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "/usr/lib/python3.5/urllib/request.py", line 471, in open
    response = meth(req, response)
  File "/usr/lib/python3.5/urllib/request.py", line 581, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/lib/python3.5/urllib/request.py", line 509, in error
    return self._call_chain(*args)
  File "/usr/lib/python3.5/urllib/request.py", line 443, in _call_chain
    result = func(*args)
  File "/usr/lib/python3.5/urllib/request.py", line 589, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
dstftw commented 8 years ago

Can you watch it in browser in the first place?

Shudouken commented 8 years ago

Yes, it works in browser without problems

dstftw commented 8 years ago

Works fine for me:

> youtube-dl https://www.facebook.com/myspass/videos/10153760344058119/ -v
[debug] System config: []
[debug] User config: []
[debug] Command-line args: [u'https://www.facebook.com/myspass/videos/10153760344058119/', u'-v']
[debug] Encodings: locale cp1251, fs mbcs, out cp866, pref cp1251
[debug] youtube-dl version 2015.12.18
[debug] Git HEAD: e462474
[debug] Python version 2.6.6 - Windows-2003Server-5.2.3790-SP2
[debug] exe versions: ffmpeg N-75573-g1d0487f, ffprobe N-75573-g1d0487f, rtmpdump 2.4
[debug] Proxy map: {}
[facebook] 10153760344058119: Downloading webpage
[debug] Invoking downloader on u'https://video.xx.fbcdn.net/hvideo-xaf1/v/t42.1790-2/12415209_784485838344799_2103917530_n.mp4?efg=eyJ2ZW5jb2RlX3RhZyI6InFmXzQyNndfY3JmXzIzX21haW5fMy4wX3AxaGNtdjRfc2QifQ%3D%3D&oh=3e86af6cd1a59ca149e7b9b0273168fd&oe=5676B2D1'
[download] Resuming download at byte 130048
[download] Destination: Endlich - Elton im Interview! Dazu spielt Elton gegen Korinna (TV totals next ...-10153760344058119.mp4
[download]   0.8% of 31.16MiB at 290.62KiB/s ETA 01:48
ERROR: Interrupted by user
Shudouken commented 8 years ago

Is there any way to force a 2.* python version? Maybe that's the problem.

dstftw commented 8 years ago

No, that's not a problem.

coderkd10 commented 8 years ago

works fine for me as well. Also python3 is not a problem-

> python3 -m youtube_dl -v https://www.facebook.com/myspass/videos/10153760344058119/
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['-v', 'https://www.facebook.com/myspass/videos/10153760344058119/']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2015.12.18
[debug] Git HEAD: c240ab6
[debug] Python version 3.4.3 - Linux-3.13.0-73-generic-x86_64-with-Ubuntu-14.04-trusty
[debug] exe versions: avconv 9.18-6, avprobe 9.18-6, ffmpeg 0.8.7-6, rtmpdump 2.4
[debug] Proxy map: {}
[facebook] 10153760344058119: Downloading webpage
[debug] Invoking downloader on 'https://video-cdg2-1.xx.fbcdn.net/hvideo-xaf1/v/t42.1790-2/12415209_784485838344799_2103917530_n.mp4?efg=eyJ2ZW5jb2RlX3RhZyI6InFmXzQyNndfY3JmXzIzX21haW5fMy4wX3AxaGNtdjRfc2QifQ%3D%3D&oh=51b23edc6fe0f355d518ef2f78fc533e&oe=567777B1'
[download] Destination: Endlich - Elton im Interview! Dazu spielt Elton gegen Korinna (TV totals next ...-10153760344058119.mp4
[download] 100% of 31.16MiB in 00:04
Shudouken commented 8 years ago

works for me now too with a newer version of youtube-dl, but I still don't know what the problem was.