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

udemy: 403 Forbidden error: Unable to download JSON metadata #23520

Closed SwapnilSoni1999 closed 4 years ago

SwapnilSoni1999 commented 4 years ago

Checklist

Verbose log

[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['--cookies', '/home/sonisins/Downloads/cookies.txt', '-u', 'PRIVATE', '-p', 'PRIVATE', '-o', './%(playlist)s/%(chapter_number)s-%(chapter)s/%(autonumber)03d-%(title)s.%(ext)s', '--verbose', 'https://www.udemy.com/course/nodejs-the-complete-guide/learn/v4/content']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8
[debug] youtube-dl version 2019.12.25
[debug] Python version 3.8.1 (CPython) - Linux-5.4.6-arch1-1-x86_64-with-glibc2.2.5
[debug] exe versions: ffmpeg 4.2.1, ffprobe 4.2.1, rtmpdump 2.4
[debug] Proxy map: {}
[udemy:course] Downloading login popup
[udemy:course] course: Downloading webpage
[udemy:course] 1879018: Downloading course curriculum
[download] Downloading playlist: 1879018
[udemy:course] playlist 1879018: Collected 430 video ids (downloading 430 of them)
[download] Downloading video 1 of 430
[udemy] Downloading login popup
[udemy] 11561804: Downloading webpage
[udemy] 11561804: Downloading lecture JSON
[udemy] 11561804: Downloading lecture JSON
ERROR: Unable to download JSON metadata: HTTP Error 403: Forbidden (caused by <HTTPError 403: 'Forbidden'>); 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.8/site-packages/youtube_dl/extractor/common.py", line 627, in _request_webpage
    return self._downloader.urlopen(url_or_request)
  File "/usr/lib/python3.8/site-packages/youtube_dl/YoutubeDL.py", line 2237, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "/usr/lib/python3.8/urllib/request.py", line 531, in open
    response = meth(req, response)
  File "/usr/lib/python3.8/urllib/request.py", line 640, in http_response
    response = self.parent.error(
  File "/usr/lib/python3.8/urllib/request.py", line 569, in error
    return self._call_chain(*args)
  File "/usr/lib/python3.8/urllib/request.py", line 502, in _call_chain
    result = func(*args)
  File "/usr/lib/python3.8/urllib/request.py", line 649, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)

Description

I'm using https://chrome.google.com/webstore/detail/cookiestxt/njabckikapfpffapmjgojcnbfjonfjfg?hl=en to save cookies and when I use youtube-dl it shows 403 error

SwapnilSoni1999 commented 4 years ago

I've seen other closed issues it was just stupid please check what's wrong! Thanks