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
129.77k stars 9.79k forks source link

Udemy - No video formats found #29925

Open Zeddex opened 2 years ago

Zeddex commented 2 years ago

Checklist

Verbose log

./youtube-dl.exe --cookies udemy.com_cookies.txt --verbose -o '~/udemy-blockchain/%(playlist)s/%(chapter_number)s - %(chapter)s/%(title)s.%(ext)s' https://www.udemy.com/blockchain-developer/
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['--cookies', 'udemy.com_cookies.txt', '--verbose', '-o', '~/udemy-blockchain/%(playlist)s/%(chapter_number)s - %(chapter)s/%(title)s.%(ext)s', 'https://www.udemy.com/blockchain-developer/']
[debug] Encodings: locale cp1251, fs mbcs, out cp866, pref cp1251
[debug] youtube-dl version 2021.06.06
[debug] Python version 3.4.4 (CPython) - Windows-10-10.0.19041
[debug] exe versions: none
[debug] Proxy map: {}
[udemy:course] blockchain-developer: Downloading webpage
[udemy:course] 1172526: Downloading course curriculum
[download] Downloading playlist: 1172526
[udemy:course] playlist 1172526: Collected 121 video ids (downloading 121 of them)
[download] Downloading video 1 of 121
[udemy] 6846516: Downloading webpage
[udemy] 6846516: Downloading lecture JSON
[udemy] 22610630: Downloading m3u8 information
[debug] Default format spec: best/bestvideo+bestaudio
[debug] Invoking downloader on 'https://www.udemy.com/assets/22610630/files/2020-03-01_13-29-53-b1af010e8a29298d952aba5ea685043c/2/hls/AVC_1920x1080_6400k_AAC-HE_64k/aa001a1334874de0b44acad3189eaa6dcf6d.m3u8?provider=cloudfront&token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE2MzExMTU1ODEsInBhdGgiOiIyMDIwLTAzLTAxXzEzLTI5LTUzLWIxYWYwMTBlOGEyOTI5OGQ5NTJhYmE1ZWE2ODUwNDNjLzIvIn0._UTSi-fQLDZ_1hqKWRHOvwgtlva7Ljmp0myUtGBX5ic&v=1'
[hlsnative] Downloading m3u8 manifest
[hlsnative] Total fragments: 50
[download] Destination: C:\Users\user\udemy-blockchain\1172526\1 - A Quick Introduction into the Course\Quick Introduction Before Commencing With This Course.mp4
[download] 100% of 209.59MiB in 00:17
WARNING: 22610630: malformed AAC bitstream detected. Install ffmpeg or avconv to fix this automatically.
[download] Downloading video 2 of 121
[udemy] 6846544: Downloading webpage
[udemy] 6846544: Downloading lecture JSON
ERROR: No video formats found; 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.
Traceback (most recent call last):
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmpkqxnwl31\build\youtube_dl\YoutubeDL.py", line 815, in wrapper
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmpkqxnwl31\build\youtube_dl\YoutubeDL.py", line 836, in __extract_info
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmpkqxnwl31\build\youtube_dl\extractor\common.py", line 534, in extract
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmpkqxnwl31\build\youtube_dl\extractor\udemy.py", line 408, in _real_extract
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\ytdl-org\tmpkqxnwl31\build\youtube_dl\extractor\common.py", line 1374, in _sort_formats
youtube_dl.utils.ExtractorError: No video formats found; 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.

Description

I'm trying to download video from udemy, 1st video downloads normal, but after that I got the error

darryl-dixon commented 2 years ago

I've noticed that this occurs when playlist shows a "Text" item instead of a course video, it doesn't seem to be handled.

darryl-dixon commented 2 years ago

Correction, it appears that Udemy have started to encrypt some of their courses, which isn't handled in the script

what1s1ove commented 2 years ago

Right! I think it happened quite recently (by the way, Udemy has recently changed the design) @darryl-dixon , Could you please tell me if it is possible to fix it somehow, or is it planned to fix it in the next versions of the script?

t-node commented 2 years ago

same issue with me too

dronezzzko commented 2 years ago

Any updates?

Grolicek commented 2 years ago

same problem: youtube_dl.utils.DownloadError

i got it on this url

DanteEnigus commented 2 years ago

Same issue. I'm working with the python library and hosting a cloud application.

The issue comes up when I use YoutubeDL.py/extract_info(). It happens in <10% on cases and isn't dependent on the URL. I'm only using it with youtube videos and it might work fine on a URL once but after an application restart the issue is there until another restart.

Most videos work on the first try and the output is as follows: [youtube]

At this point the rest of the videos I try spit out the same "no video format" error until the next restart which may fix it.

The issue also occurs seemingly randomly, after I've downloaded many videos in a session it gets stuck on one or another.

Important note, I'm not 100% sure it fixes itself because of the restart as I usually do it pretty quickly after a failure. Trying to call extract_info() with another instance of the YoutubeDL class, even with different settings, yields the same results. My point is, either the phenomenon is short-lived or somehow session-dependent? Anyone else to verify my results? Thanks in advance.

Additional info: only downloading from youtube, the URLs aren't broken and I'm using the latest version.

[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, pref UTF-8 [debug] youtube-dl version 2021.12.17 [debug] Python version 3.9.4 (CPython) - Linux-4.4.0-1097-aws-x86_64-with-glibc2.31 [debug] exe versions: ffmpeg N-60236-gffb000fff8-static, ffprobe N-60236-gffb000fff8-static [debug] Proxy map: {}

SolosoftNL commented 2 years ago

Same problem.. any fix?

dirkf commented 2 years ago

Also see why a dedicated tool for Udemy was abandoned.