Giter VIP home page Giter VIP logo

udemy-downloader's Introduction

Udemy Downloader with DRM support

forthebadge forthebadge forthebadge forthebadge GitHub forks GitHub Repo stars GitHub

NOTE

  • This tool will not work without decryption keys. Do not bother installing unless you already have keys or can obtain them!
  • If you ask about keys in the issues, your message will be deleted and you will be blocked.
  • Downloading courses is against Udemy's Terms of Service, I am NOT held responsible for your account getting suspended as a result from the use of this program!
  • This program is WIP, the code is provided as-is and I am not held resposible for any legal issues resulting from the use of this program.

Description

Utility script to download Udemy courses, has support for DRM videos but requires the user to acquire the decryption key (for legal reasons).
Windows is the primary development OS, but I've made an effort to support Linux also (Mac untested).

Requirements

The following are a list of required third-party tools, you will need to ensure they are in your systems path and that typing their name in a terminal invokes them.

Note: These are seperate requirements that are not installed with the pip command! You will need to download and install these manually!

  • Python 3
  • ffmpeg - This tool is also available in Linux package repositories.
    • NOTE: It is recommended to use a custom build from the yt-dlp team that contains various patches for issues when used alongside yt-dlp, however it is not required. Latest builds can be found here
  • aria2/aria2c - This tool is also available in Linux package repositories
  • shaka-packager
  • yt-dlp - This tool is also available in Linux package repositories, but can also be installed using pip if desired (pip install yt-dlp)

Usage

quick and dirty how-to

You will need to get a few things before you can use this program:

  • Decryption Key ID
  • Decryption Key
  • Udemy Course URL
  • Udemy Bearer Token (aka acccess token for udemy-dl users)
  • Udemy cookies (only required for subscription plans - see Udemy Subscription Plans)

Setting up

  • rename .env.sample to .env (you only need to do this if you plan to use the .env file to store your bearer token)
  • rename keyfile.example.json to keyfile.json

Acquire Bearer Token

  • Firefox: Udemy-DL Guide
  • Chrome: Udemy-DL Guide
  • If you want to use the .env file to store your Bearer Token, edit the .env and add your token.

Key ID and Key

It is up to you to acquire the key and key ID. Please DO NOT ask me for help acquiring these, decrypting DRM protected content can be considered piracy. The tool required for this has already been discused in a GitHub issue.

  • Enter the key and key id in the keyfile.json
  • keyfile example
  • example key and kid from console

Cookies

To download a course included in a subscription plan that you did not purchase individually, you will need to use cookies. You can also use cookies as an alternative to Bearer Tokens.

The program can automatically extract them from your browser. You can specify what browser to extract cookies from with the --browser argument. Supported browsers are:

  • chrome
  • firefox
  • opera
  • edge
  • brave
  • chromium
  • vivaldi
  • safari

Ready to go

You can now run the program, see the examples below. The course will download to out_dir.

Advanced Usage

usage: main.py [-h] -c COURSE_URL [-b BEARER_TOKEN] [-q QUALITY] [-l LANG] [-cd CONCURRENT_DOWNLOADS] [--disable-ipv6] [--skip-lectures] [--download-assets]
               [--download-captions] [--download-quizzes] [--keep-vtt] [--skip-hls] [--info] [--id-as-course-name] [-sc] [--save-to-file] [--load-from-file]
               [--log-level LOG_LEVEL] [--browser {chrome,firefox,opera,edge,brave,chromium,vivaldi,safari}] [--use-h265] [--h265-crf H265_CRF] [--h265-preset H265_PRESET]
               [--use-nvenc] [--out OUT] [--continue-lecture-numbers]

Udemy Downloader

options:
  -h, --help            show this help message and exit
  -c COURSE_URL, --course-url COURSE_URL
                        The URL of the course to download
  -b BEARER_TOKEN, --bearer BEARER_TOKEN
                        The Bearer token to use
  -q QUALITY, --quality QUALITY
                        Download specific video quality. If the requested quality isn't available, the closest quality will be used. If not specified, the best quality will be
                        downloaded for each lecture
  -l LANG, --lang LANG  The language to download for captions, specify 'all' to download all captions (Default is 'en')
  -cd CONCURRENT_DOWNLOADS, --concurrent-downloads CONCURRENT_DOWNLOADS
                        The number of maximum concurrent downloads for segments (HLS and DASH, must be a number 1-30)
  --disable-ipv6        If specified, ipv6 will be disabled in aria2
  --skip-lectures       If specified, lectures won't be downloaded
  --download-assets     If specified, lecture assets will be downloaded
  --download-captions   If specified, captions will be downloaded
  --download-quizzes    If specified, quizzes will be downloaded
  --keep-vtt            If specified, .vtt files won't be removed
  --skip-hls            If specified, hls streams will be skipped (faster fetching) (hls streams usually contain 1080p quality for non-drm lectures)
  --info                If specified, only course information will be printed, nothing will be downloaded
  --id-as-course-name   If specified, the course id will be used in place of the course name for the output directory. This is a 'hack' to reduce the path length
  -sc, --subscription-course
                        Mark the course as a subscription based course, use this if you are having problems with the program auto detecting it
  --save-to-file        If specified, course content will be saved to a file that can be loaded later with --load-from-file, this can reduce processing time (Note that asset
                        links expire after a certain amount of time)
  --load-from-file      If specified, course content will be loaded from a previously saved file with --save-to-file, this can reduce processing time (Note that asset links
                        expire after a certain amount of time)
  --log-level LOG_LEVEL
                        Logging level: one of DEBUG, INFO, ERROR, WARNING, CRITICAL (Default is INFO)
  --browser {chrome,firefox,opera,edge,brave,chromium,vivaldi,safari}
                        The browser to extract cookies from
  --use-h265            If specified, videos will be encoded with the H.265 codec
  --h265-crf H265_CRF   Set a custom CRF value for H.265 encoding. FFMPEG default is 28
  --h265-preset H265_PRESET
                        Set a custom preset value for H.265 encoding. FFMPEG default is medium
  --use-nvenc           Whether to use the NVIDIA hardware transcoding for H.265. Only works if you have a supported NVIDIA GPU and ffmpeg with nvenc support
  --out OUT, -o OUT     Set the path to the output directory
  --continue-lecture-numbers, -n
                        Use continuous lecture numbering instead of per-chapter
  • Passing a Bearer Token and Course ID as an argument
    • python main.py -c <Course URL> -b <Bearer Token>
    • python main.py -c https://www.udemy.com/courses/myawesomecourse -b <Bearer Token>
  • Download a specific quality
    • python main.py -c <Course URL> -q 720
  • Download assets along with lectures
    • python main.py -c <Course URL> --download-assets
  • Download assets and specify a quality
    • python main.py -c <Course URL> -q 360 --download-assets
  • Download captions (Defaults to English)
    • python main.py -c <Course URL> --download-captions
  • Download captions with specific language
    • python main.py -c <Course URL> --download-captions -l en - English subtitles
    • python main.py -c <Course URL> --download-captions -l es - Spanish subtitles
    • python main.py -c <Course URL> --download-captions -l it - Italian subtitles
    • python main.py -c <Course URL> --download-captions -l pl - Polish Subtitles
    • python main.py -c <Course URL> --download-captions -l all - Downloads all subtitles
    • etc
  • Skip downloading lecture videos
    • python main.py -c <Course URL> --skip-lectures --download-captions - Downloads only captions
    • python main.py -c <Course URL> --skip-lectures --download-assets - Downloads only assets
  • Keep .VTT caption files:
    • python main.py -c <Course URL> --download-captions --keep-vtt
  • Skip parsing HLS Streams (HLS streams usually contain 1080p quality for Non-DRM lectures):
    • python main.py -c <Course URL> --skip-hls
  • Print course information only:
    • python main.py -c <Course URL> --info
  • Specify max number of concurrent downloads:
    • python main.py -c <Course URL> --concurrent-downloads 20
    • python main.py -c <Course URL> -cd 20
  • Cache course information:
    • python main.py -c <Course URL> --save-to-file
  • Load course cache:
    • python main.py -c <Course URL> --load-from-file
  • Change logging level:
    • python main.py -c <Course URL> --log-level DEBUG
    • python main.py -c <Course URL> --log-level WARNING
    • python main.py -c <Course URL> --log-level INFO
    • python main.py -c <Course URL> --log-level CRITICAL
  • Use course ID as the course name:
    • python main.py -c <Course URL> --id-as-course-name
  • Encode in H.265:
    • python main.py -c <Course URL> --use-h265
  • Encode in H.265 with custom CRF:
    • python main.py -c <Course URL> --use-h265 -h265-crf 20
  • Encode in H.265 with custom preset:
    • python main.py -c <Course URL> --use-h265 --h265-preset faster
  • Encode in H.265 using NVIDIA hardware transcoding:
    • python main.py -c <Course URL> --use-h265 --use-nvenc
  • Use continuous numbering (don't restart at 1 in every chapter):
    • python main.py -c <Course URL> --continue-lecture-numbers
    • python main.py -c <Course URL> -n

If you encounter errors while downloading such as

errorCode=1 Network problem has occurred. cause:Unknown socket error 10051 (0x2743)

or

errorCode=1 Network problem has occurred. cause:A socket operation was attempted to an unreachable network.

Then try disabling ipv6 in aria2 using the --disable-ipv6 option

Support

if you want help using the program, join my Discord server or use GitHub Issues

Credits

License

All code is licensed under the MIT license

and finally, donations!

Woo, you made it this far!

I spend a lot of time coding things, and almost all of them are for nothing in return. When theres a lot of use of a program I make, I try to keep it updated, fix bugs, and even implement new features! But after a while, I do run out of motivation to keep doing it. If you like my work, and can help me out even a little, it would really help me out. If you are interested, you can find all the available options here. Even if you don't, thank you anyways!

udemy-downloader's People

Contributors

4l3j0ok avatar alvarobeiro avatar biplobsd avatar debakarr avatar evyatar avatar jayapraveen avatar mthibaut-hbc avatar perfectra1n avatar puyodead1 avatar rickeymandraque avatar runtlb64 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

udemy-downloader's Issues

Assets download problem when 2 assets have the same name in a same chapter

It could be a good idea to add object_index to assets because when You try to download a course with 2 assets with the same name in the same chapter, You got a error ....

I06/01 13:16:16 [ERROR] CUID#7 - Download aborted. URI=https://att-c.udemycdn.com/2021-04-20_07-32-14-b1cd60e7a5afc2dac7fbab5003bcb8a1/original.zip?response-content-disposition=attachment%3B+filename%3DCourseDBFunction.zip&Expires=1622556964&Signature=XXXXXXXX
Exception: [AbstractCommand.cc:403] errorCode=13 URI=https://att-c.udemycdn.com/2021-04-20_07-32-14-b1cd60e7a5afc2dac7fbab5003bcb8a1/original.zip?response-content-disposition=attachment%3B+filename%3DCourseDBFunction.zip&Expires=1622556964&Signature=XXXXXXXX
-> [RequestGroup.cc:784] errorCode=13 File c:/udemy-downloader/out_dir/exam-microsoft-azure-dev/04 Develop Azure compute solutions - Azure Web Apps and Azure Functions/CourseDBFunction.zip exists, but a control file(*.aria2) does not exist. Download was canceled in order to prevent your file from being truncated to 0. If you are sure to download the file all over again, then delete it or add --allow-overwrite=true option and restart aria2.

06/01 13:20:48 [ERROR] CUID#7 - Download aborted. URI=https://att-c.udemycdn.com/2021-04-20_07-35-15-82a6966be87c277bcdb41df01a145775/original.zip?response-content-disposition=attachment%3B+filename%3DCourseDBFunction.zip&Expires=1622556964&Signature=XXXXXXXX
Exception: [AbstractCommand.cc:403] errorCode=13 URI=https://att-c.udemycdn.com/2021-04-20_07-35-15-82a6966be87c277bcdb41df01a145775/original.zip?response-content-disposition=attachment%3B+filename%3DCourseDBFunction.zip&Expires=1622556964&Signature=XXXXXXXX
-> [RequestGroup.cc:784] errorCode=13 File c:/udemy-downloader/out_dir/exam-microsoft-azure-dev/04 Develop Azure compute solutions - Azure Web Apps and Azure Functions/CourseDBFunction.zip exists, but a control file(*.aria2) does not exist. Download was canceled in order to prevent your file from being truncated to 0. If you are sure to download the file all over again, then delete it or add --allow-overwrite=true option and restart aria2.

[BUG] Could not send HEAD request; HTTP Error 403

Describe the bug
Upon downloading from Udemy (non-DRM course), it downloads the subtitles, but not the videos (on a particular course, it downloaded 2 videos out of around 100 - and I can't work out why it chose to download those 2 videos).

Errors:
> Lecture doesn't have DRM, attempting to download...
====== Selected quality: hls 1080
[generic] aa00e4239113d645bddff6d584bc0f39f04d.m3u8?provider=cloudfront&token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJwYXRoIjoiMjYwNTUzNC8yMDUzOTk1Ni8yMDE5LTEwLTI0XzA4LTExLTUzLWZiYjU5MWFhYTg0NTAwYjUwNzQwZDdjMWQ0ZTQ3ODkyLyIsImV4cCI6MTYzNDU4MTExNn0: Requesting header
WARNING: [generic] Could not send HEAD request to ... : HTTP Error 403: Forbidden
[generic] ... .m3u8?provider=cloudfront&token=... Downloading webpage
ERROR: [generic] Unable to download webpage: HTTP Error 403: Forbidden (caused by <HTTPError 403: 'Forbidden'>); please report this issue on https://github.com/yt-dlp/yt-dlp . Make sure you are using the latest version; see https://github.com/yt-dlp/yt-dlp on how to update. Be sure to call yt-dlp with the --verbose flag and include its complete output.
> Processing 0 asset(s) for lecture...

To Reproduce
Steps to reproduce the behavior:
As per above.

Desktop (please complete the following information):

  • OS: Windows 10

Additional context
No issues with bearer token, as it is able to successfully log in and download the subtitle files.

how to get key and key id?

how to get key and key id ?
plz help
i used widevine-l3-decryptor but error :
"Can't verify license request signature; either the platform is wrong or the key has changed!"

Error on fetching courses

Fetching Course data, this may take a minute...
An error occurred while trying to fetch the course data! <script async src='/cdn-cgi/bm/cv/669835187/api.js'></script>

502 Bad Gateway


The server returned an invalid or incomplete response.

<script type="text/javascript">(function(){window['__CF$cv$params']={r:'655ae886ab340a8c',m:'5001597e4bb7d8d50da696aa8339476dd63c7729-1622073074-1800-AXbWxGbaFMeSAV/uxr5JKU5lbn4PUpeIXjW+TdGXaHYPz7pnxG57wKiJuhXayDd5G5RE2qrPuEwTose7SXizpj9I3M1CWttGEfBGTAKEBSqzCgsSUa3bcZwB/0xEAqbFWnd//39qiDoHrRV84xwLpb97Ehe2HtriVntam+KUP0biL3jeoqR3z4CKSWit38crXcSwhyVeU75TSBMh4dxGrwARh5eNTN4baf/F6VjqYZ24r8dErn5bHCLgmep7mf76S2u6mfoV9l9gRXNV5bZdVMpP9MJw7AvtYbi4bVGQ/Hfgbb94hDGW2zU91VTr3DBdVXh/gErbMT86l9vZpPJcLuOjklSLZ9matcDGt+Riz/lGyUSN40iYOiYmWw2HZ5TjB4VNI3icRi+nFZcKbPYXN9ctzQB4mZdURKYT7n5lxokOnT5siOqhMbMGnSan7zJqAuMi8Tg40GFxU12UvkJDPY3XFCs6XsoL8EUkIIDZhMEFZhKtkuLr2WWCvNmm3Tr7NbJabxxFZTPxtSw76SS0y3lGxWYknW/8bguRQ7sAiGvi5w4f108P44zlI1CPDT1wRir0pyodh6+bnOikxSJS+AumpbuUKAF/MjOAwyy+YTOKmE9R3WtNANN+ztR22vjpyg==',s:[0xc5e4e94200,0x334e7a8097],}})();</script>

[BUG] pdf assets are creating with random file names at beginning

Describe the bug
pdf assets are creating with random file names at beginning

Expected behavior
Master branch versions able to download pdf with correct file names

Screenshots
image

Desktop (please complete the following information):

  • OS: Windows 10
  • You are running version 1.2.2 (development branch)

Error: Please accept our latest Terms of Service.

Im getting this error while fetching the course data:
Fetching Course data, this may take a minute...
An error occurred while trying to fetch the course data! {"error": "Please accept our latest Terms of Service."}

[Feature Request] add command line option to choose ffmpeg encoders in H265 for Hardware acceleration support and custom frame rate

Is your feature request related to a problem? Please describe.
ffmpeg H265 supports bellow encoders

V....D libx265 libx265 H.265 / HEVC (codec hevc)
V....D hevc_amf AMD AMF HEVC encoder (codec hevc)
V....D hevc_nvenc NVIDIA NVENC hevc encoder (codec hevc)
V..... hevc_qsv HEVC (Intel Quick Sync Video acceleration) (codec hevc)

by default libx265 is used, which is a software encoder and consume total CPU with less encoding speed

Also by default each video frame rate is 30 FPS, i want to change it to 24 for faster encoding and less size,
i think 24 FPS if fine for tutorials like udemy, as they are not a motion sensitive like action movies and gaming video's

can give these two command line options please

filenotfound error for keyfile.name

filenotfound error for keyfile.json

C:\Users\username\Downloads\udemy-downloader-master>py main.py
Traceback (most recent call last):
File "C:\Users\username\Downloads\udemy-downloader-master\main.py", line 36, in
with open(keyfile_path, 'r') as keyfile:
FileNotFoundError: [Errno 2] No such file or directory: 'C:\Users\username\Downloads\udemy-downloader-master\keyfile.json'

Encrypted files downloaded but not merged

Encrypted files are downloaded normally but two files per video one with mp4 and one with m4a extensions and they are not merged
Does anyone have an idea how to merge the whole directory?

getting this error in new version

Processing 240 of 245
Processing 244 of 245
Traceback (most recent call last):
File "main.py", line 1743, in
concurrent_connections)
TypeError: parse_new() takes 1 positional argument but 9 were given

[BUG] "Course ID not found" error on Courses that were obtained Through the Personal Plan

Describe the bug
Downloading of courses that were obtained through subscriptions such as the Personal Plan Free Trial do not work. I am able to download courses that I purchased but not Personal Plan courses.

To Reproduce
Steps to reproduce the behavior:

  1. Get the Personal Plan free trial.
  2. Click on a course that is provided via the subscription.
  3. Run the following command to reproduce the error: main.py -c https://www.udemy.com/course/wpf-xaml-c-sharp/ --info
  4. See error:
    Login Success
    > Fetching course information, this may take a minute...
    Downloading course information, course id not found ..
    It seems either you are not enrolled or you have to visit the course atleast once while you are logged in.

Expected behavior
Course should download the same way that purchased courses download

Desktop

  • OS: Windows 10
  • Python 3.9

Additional context
I was able to successfully download a course that I had purchased, but not for one given to me by the subscription.

Getting problem with pip modules

i am trying to downloads course but getting error,

image

i am using udemy business access tokens
windows 10 x64 with python 3.9.5

Please help me , i f i need any additional steps
i am also ready to share these if required
Decryption Key ID
Decryption Key
Udemy Course ID
Udemy Bearer Token

index error: list index out of range

am getting an error after following all the steps. I have retrieved all the information but i guess there is something wrong with the code.
Error
Fetching Course data, this may take a minute...
Course data retrieved!
Traceback (most recent call last):
File "main.py", line 288, in
parse(data["results"])
File "main.py", line 242, in parse
chapters[-1]["lectures"].append(obj)
IndexError: list index out of range
error

some courses videos are skipping

some courses videos skipping like for this course you can check (if you have a business account or I can provide you token & course id you can check)

https://www.udemy.com/course/an-entire-mba-in-1-courseaward-winning-business-school-prof/

for this course, its downloading 1st video on every module and ignoring other videos :-(

https://www.udemy.com/course/ielts-band-7-preparation-course/
Image

for this course, in the middle after downloading half stuck with an error, maybe it's for resolution not found, but every course support at least 720P for all videos. in this case, you can apply a system, if given resolution not found in the videos, they can download at least the last available resolution on videos.
Note:- I am downloading 720p resolution

[Feature Request] Path length detection +chapter title or lecture title truncation if needed

First of all, thank you for this program. It works extremely well for backing up the Udemy courses I've purchased.

I ran into an issue with one of my courses that has very long chapter title and lecture titles which caused the path length to exceed the Windows 255 character limit. This caused lots of weird errors about "cannot write to file" or "file not found" during the download process.

Example (256 characters long): Z:\Udemy\out_dir\crash-course-electronics-and-pcb-design\08 - Graduating to Design Engineer_ CircuitMaker Fundamentals and Real-World Projects/004 CircuitMaker Fundamentals_ Magic Wand 555 Timer Design & Parts Selection Process.encrypted.m4a.part.frag.urls

I worked around the issue by putting the udemy-downloader folder in the root folder of my drive, renaming the udemy-downloader folder to just "Udemy", and finally I had to add a line to the main.py to truncate any chapter title greater than 51 characters:

for chapter in _udemy.get("chapters"):
        chapter_title = chapter.get("chapter_title")
        chapter_title = chapter_title[:51]                                           <<<
        chapter_index = chapter.get("chapter_index")
        chapter_dir = os.path.join(course_dir, chapter_title)
        if not os.path.exists(chapter_dir):
            os.mkdir(chapter_dir)

This all worked fine for me but it might be worth adding a mechanism to detect if the program is going to try to access a path longer than 256 characters, and if so either just arbitrarily truncate the chapter titles and lecture titles if necessary, or give the user an option to select what to truncate and how much. Or even just print an error and quit rather than have the user receive lots of weird errors. For me, I figured the information in the long lecture titles was more useful so I opted to truncate the chapter titles. Although, I did add a txt file with the full chapter titles "just in case".

Just some thoughts I thought I'd share. Thanks again!

[BUG] yt-dlp throwing up 403 HTTPError exception

Seems like yt-dlp is broken. I am getting the following error message with a status code of 403.
I have updated yt-dlp to the latest version too, but the same issue persists. Not sure if it is from the yt-dlp end, or it's a bug in your code, so raising the issue here.

main.py --course-url <my-course-url> --bearer <my-auth-key> --download-captions --download-assets
Login Success
> Fetching course information, this may take a minute...
> Course information retrieved!
> Fetching course content, this may take a minute...
> Course content retrieved!
> Processing course data, this may take a minute.
Processing 1 of 71
Processing 2 of 71
Processing 4 of 71
ERROR: Unable to download webpage: HTTP Error 403: Forbidden (caused by <HTTPError 403: 'Forbidden'>); please report this issue on  https://github.com/yt-dlp/yt-dlp . Make sure you are using the latest version; see  https://github.com/yt-dlp/yt-dlp  on how to update. Be sure to call yt-dlp with the --verbose flag and include its complete output.
Error fetching MPD streams: 'ERROR: Unable to download webpage: HTTP Error 403: Forbidden (caused by <HTTPError 403: 'Forbidden'>); please report this issue on  https://github.com/yt-dlp/yt-dlp . Make sure you are using the latest version; see  https://github.com/yt-dlp/yt-dlp  on how to update. Be sure to call yt-dlp with the --verbose flag and include its complete output.'
Processing 5 of 71
ERROR: Unable to download webpage: HTTP Error 403: Forbidden (caused by <HTTPError 403: 'Forbidden'>); please report this issue on  https://github.com/yt-dlp/yt-dlp . Make sure you are using the latest version; see  https://github.com/yt-dlp/yt-dlp  on how to update. Be sure to call yt-dlp with the --verbose flag and include its complete output.
Error fetching MPD streams: 'ERROR: Unable to download webpage: HTTP Error 403: Forbidden (caused by <HTTPError 403: 'Forbidden'>); please report this issue on  https://github.com/yt-dlp/yt-dlp . Make sure you are using the latest version; see  https://github.com/yt-dlp/yt-dlp  on how to update. Be sure to call yt-dlp with the --verbose flag and include its complete output.'

Windows: "the command line is too long" in "copy /b" command for large lectures (more than 1hr 20mins)

details: https://docs.microsoft.com/en-US/troubleshoot/windows-client/shell-experience/command-line-string-limitation

The workaround for now I am using is dividing the copy /b into multiple batches.
like,
touch encrypted_video.mp4 encrypted_audio.mp4
then, copy /b encrypted_video.mp4+video_0......+video_249.mp4
..next batch..
copy /b encrypted_video.mp4+video_250......+video_499.mp4 .. and so on.

So the number of segment i have is ~1045.

feature request, Please add one more sub directory after "out_dir" with cource id

I am trying to download two cources at a time ( because downloading streams one after another in 1 videio , which takes longer time, even if i have a good internet speed , for me it takes 5 hours per cource
but all files are going to "out_dir" folder, so it will be difficult to separate them later with respect to cource

is it possible to add one more sub folder level with cource id please

widevine

widevine chrome extension stopped working on udemy,
can you help me?

[Feature Request] HEVC H.265

First i would thank you @Puyodead1 for his efforts and time for developing tis repo
with this tool, I am sharing few coerces on cloud drive (like one drive) for my students, and they can able to download and access from internet

But this tool creating video's in AVC -H.264 format , so it consumes much disk space and internet bandwidth for upload and downlead. and ffmpg supports HEVC H265 format, so, i request to give on option to create the video's in H265 format

For more details about HEVC can be found here

i am using MediaInfo tool for identifying the codec. and HEVC is the best codec for high quality video's with less disk space
also request to integrate sub titles inside .MP4 container, so it will reduce the number of files in disks, and helpful for my student's to handle,

Thank you!

Proxy option feature

HI, can you add proxy option into this tool, I need to use proxy for specific purpose

May 31

as of May 31, no such tools will become useless

File not found error when download start

Hi,

first of all, thanks for creating this tool. I'm sure this can make the trick to download my purchased courses in Udemy. Though this, I'm getting to different errors:

I added required libraries to the path:

image

and also edit my .env file (though finally I write Bearer token in command line). File keyfile.json is renamed but I kept as is, since I think I don't neet it because I actually have purchased access to this courses.

  1. Running python main.py -c https://...#overview -b xxx

After all lectures are processed, I get this error:

image

Which is something like "FileNotFoundError: [WinError 2] System cannot find the specified file". Only a couple of html files were downloaded.

  1. Running python main.py -c https://...#overview -b xxx --skip-hls

After all lectures are processed, I actually download several videos, but...:

image
image

I've got no idea what is failing and how to solve.

External link could be managed more graceful

For External Link maybe You can implement this

$filename = $index + $supplementary_asset->filename + ".url"
$data = $supplementary_asset->external_url

and you write file with name=$filename with tthe following content to create a perfect shortcut :

"[InternetShortcut]\r\nURL=" + $data

Downloading very slow

Can you please increase download speed using any method ! i am downloading 10 hour content approx. 12gb data from 2 days & i think it will be completed tomorrow. :)

Python dependency issues

Ubuntu 20.04
Python 3.8.5

bitfield won't try to install until cython is first installed.

after running pip install cython the bitfield installation gives a pretty large wall of text in an error

tried running as both root and non roott
https://pastebin.com/hVQ9bvZM

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.