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
131.89k stars 10k forks source link

Unable to download videos from Udemy #16403

Closed JSLover24 closed 6 years ago

JSLover24 commented 6 years ago

J:\Youtube>youtube-dl.exe -u xxxxxxx -p xxxxxxxx -o /Udemy/%(playlist)s/%(playlist_index)s-%(chapter)s-%(title)s.%(ext)s --batch-file udemy2.txt --verbose [debug] System config: [] [debug] User config: [] [debug] Custom config: [] [debug] Command-line args: ['-u', 'PRIVATE', '-p', 'PRIVATE', '-o', '/Udemy/%(playlist)s/%(playlist_index)s-%(chapter)s-%(title)s.%(ext)s', '--batch-file', 'udemy2.txt', '--verbose'] [debug] Batch file urls: ['https://www.udemy.com/designing-and-building-custom-apps-using-dynamics-365'] [debug] Encodings: locale cp1252, fs mbcs, out cp437, pref cp1252 [debug] youtube-dl version 2018.05.01 [debug] Python version 3.4.4 (CPython) - Windows-10-10.0.16299 [debug] exe versions: none [debug] Proxy map: {} [udemy:course] Downloading login popup [udemy:course] Logging in [udemy:course] designing-and-building-custom-apps-using-dynamics-365: Downloading webpage [udemy:course] 1621194: Downloading course curriculum [download] Downloading playlist: Designing and Building Custom Apps using Dynamics 365 [udemy:course] playlist Designing and Building Custom Apps using Dynamics 365: Collected 74 video ids (downloading 74 of them) [download] Downloading video 1 of 74 [udemy] Downloading login popup [udemy] 9838300: Downloading webpage [udemy] 9838300: Downloading lecture JSON [debug] Default format spec: best/bestvideo+bestaudio [debug] Invoking downloader on 'https://knowband-asset-bucket.s3.amazonaws.com/2018-03-29_07-27-21-c085af40e52d38dbf3f134da48ee0875/WebHD_720p.mp4' ERROR: unable to download video data: HTTP Error 403: Forbidden Traceback (most recent call last): File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmpulhs0gaq\build\youtube_dl\YoutubeDL.py", line 1900, in process_info File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmpulhs0gaq\build\youtube_dl\YoutubeDL.py", line 1839, in dl File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmpulhs0gaq\build\youtube_dl\downloader\common.py", line 365, in download File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmpulhs0gaq\build\youtube_dl\downloader\http.py", line 340, in real_download File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmpulhs0gaq\build\youtube_dl\downloader\http.py", line 109, in establish_connection File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmpulhs0gaq\build\youtube_dl\YoutubeDL.py", line 2203, in urlopen File "C:\Python\Python34\lib\urllib\request.py", line 470, in open File "C:\Python\Python34\lib\urllib\request.py", line 580, in http_response File "C:\Python\Python34\lib\urllib\request.py", line 508, in error File "C:\Python\Python34\lib\urllib\request.py", line 442, in _call_chain File "C:\Python\Python34\lib\urllib\request.py", line 588, in http_error_default urllib.error.HTTPError: HTTP Error 403: Forbidden

J:\Youtube>

vesper8 commented 6 years ago

Experiencing the same problem.. this only happens for courses where the instructors has not enabled downloads

however this was working before, furthermore I can easily download the videos despite this restriction using chrome extensions, which have no trouble at all locating the videos.. so surely this can be remedied

vesper8 commented 6 years ago

Looks like https://github.com/riazXrazor/udemy-dl already came up with the fix, so just copying his fix from the recent commits to youtube-dl should take care of this one