coursera-dl / edx-dl

A simple tool to download video lectures from edx.org (and other openedx sites)
GNU Lesser General Public License v3.0
1.93k stars 640 forks source link

ERROR: M-XlYymh714: YouTube said: Please sign in to view this video. #450

Closed shashikanth171 closed 6 years ago

shashikanth171 commented 7 years ago

🚨Please review the Troubleshooting section before reporting any issue. Don't forget also to check the current issues to avoid duplicates.

Subject of the issue

ERROR: M-XlYymh714: YouTube said: Please sign in to view this video.

Your environment

Steps to reproduce

Tell us how to reproduce this issue. Please provide us the course URL, and the specific subsection or unit if possible. https://courses.edx.org/courses/course-v1:HarvardX+CS50+X/course/

Expected behaviour

The videos should start downloading

Actual behaviour

Tell us what happens instead. If the script fails, please copy the entire output of the command or the stacktrace (don't forget to obfuscate your username and password). If you cannot copy the exception, attach a screenshot. ERROR: M-XlYymh714: YouTube said: Please sign in to view this video. Traceback (most recent call last): File "/usr/local/bin/edx-dl", line 11, in load_entry_point('edx-dl==0.1.5', 'console_scripts', 'edx-dl')() File "/usr/local/lib/python2.7/dist-packages/edx_dl/edx_dl.py", line 1061, in main download(args, selections, all_units, headers) File "/usr/local/lib/python2.7/dist-packages/edx_dl/edx_dl.py", line 840, in download headers) File "/usr/local/lib/python2.7/dist-packages/edx_dl/edx_dl.py", line 812, in download_unit skip_or_download(res_downloads, headers, args) File "/usr/local/lib/python2.7/dist-packages/edx_dl/edx_dl.py", line 771, in skip_or_download f(url, filename, headers, args) File "/usr/local/lib/python2.7/dist-packages/edx_dl/edx_dl.py", line 704, in download_url download_youtube_url(url, filename, headers, args) File "/usr/local/lib/python2.7/dist-packages/edx_dl/edx_dl.py", line 744, in download_youtube_url execute_command(cmd, args) File "/usr/local/lib/python2.7/dist-packages/edx_dl/utils.py", line 42, in execute_command raise e subprocess.CalledProcessError: Command '['youtube-dl', '--ignore-config', '-o', u'Downloaded/Introduction_to_Computer_Science/01-CS50x2017/01-%(title)s-%(id)s.%(ext)s', '-f', 'mp4', '--no-check-certificate', u'https://youtu.be/M-XlYymh714']' returned non-zero exit status 1

PhoCho commented 7 years ago

how about by using -i --ignore-errors

rbrito commented 6 years ago

If you get an error like "YouTube said: Please sign in to view this video.", then we can't do much about it.

You can try to pass your credentials to youtube-dl (see https://github.com/rg3/youtube-dl#authentication-options) with the use of edx-dl's option --youtube-dl-options.

If it doesn't work, then you will have to tell edx-dl to ignore the download of that particular video with the option --ignore-errors.

dodoslavn commented 6 years ago

Hello, iam trying to get names of all videos from youtube playlist, but iam getting this error. It show names of some videos, but then it come to one video which is somehow private and then it get stuck and doesnt continue at all, tried all parameters like "skip errors" or "retry"

youtube-dl --ignore-errors -e https://www.youtube.com/playlist?list=PLDfKAXSi6kUbSKS0DKRDNi72O_bPTg5yh ERROR: EgRjWTjb97M: YouTube said: Please sign in to view this video.

youtube-dl -u -p --ignore-errors -e https://www.youtube.com/playlist?list=PLDfKAXSi6kUbSKS0DKRDNi72O_bPTg5yh ERROR: EgRjWTjb97M: YouTube said: This video is private.

youtube-dl -U youtube-dl is up-to-date (2017.12.14) uname -a Linux AW1 4.9.0-2-amd64 #1 SMP Debian 4.9.18-1 (2017-03-30) x86_64 GNU/Linux