Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not working with latest python versions #854

Open
yuvalbeck opened this issue Jun 20, 2023 · 7 comments
Open

Not working with latest python versions #854

yuvalbeck opened this issue Jun 20, 2023 · 7 comments

Comments

@yuvalbeck
Copy link

Can anyone update the packages in the requirements to support newer versions of python many were deleted?
Thank you

@theawesomeharris
Copy link

yo man i think the package has gone obsolete.

@csyezheng
Copy link

I forked the repository and fixed it to a working version: https://github.com/csyezheng/coursera-helper

You can install it using the command:
pip install coursera-helper

@fasonche
Copy link

fasonche commented Nov 5, 2023

I forked the repository and fixed it to a working version: https://github.com/csyezheng/coursera-helper

You can install it using the command: pip install coursera-helper
@csyezheng
Hello, I am using coursera-helper trying to download
and get these errors.
Could you give me some advise to how to fix it?


Traceback (most recent call last):
File "C:\Program Files\Python310\lib\runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Program Files\Python310\lib\runpy.py", line 86, in run_code
exec(code, run_globals)
File "C:\Users\fason\AppData\Roaming\Python\Python310\Scripts\coursera-helper.exe_main
.py", line 7, in
File "C:\Users\fason\AppData\Roaming\Python\Python310\site-packages\coursera_helper\coursera_dl.py", line 256, in main
error_occurred, completed = download_class(
File "C:\Users\fason\AppData\Roaming\Python\Python310\site-packages\coursera_helper\coursera_dl.py", line 216, in download_class
return download_on_demand_class(session, args, class_name)
File "C:\Users\fason\AppData\Roaming\Python\Python310\site-packages\coursera_helper\coursera_dl.py", line 136, in download_on_demand_class
error_occurred, modules = extractor.get_modules(
File "C:\Users\fason\AppData\Roaming\Python\Python310\site-packages\coursera_helper\extractors.py", line 53, in get_modules
error_occurred, modules = self._parse_on_demand_syllabus(
File "C:\Users\fason\AppData\Roaming\Python\Python310\site-packages\coursera_helper\extractors.py", line 155, in _parse_on_demand_syllabus
links = course.extract_links_from_lecture(
File "C:\Users\fason\AppData\Roaming\Python\Python310\site-packages\coursera_helper\api.py", line 881, in extract_links_from_lecture
links = self._extract_videos_and_subtitles_from_lecture(
File "C:\Users\fason\AppData\Roaming\Python\Python310\site-packages\coursera_helper\api.py", line 1045, in _extract_videos_and_subtitles_from_lecture
videos = VideosV1.from_json(dom)
File "C:\Users\fason\AppData\Roaming\Python\Python310\site-packages\coursera_helper\api.py", line 524, in from_json
videos = [VideoV1(resolution, links['mp4VideoUrl'])
File "C:\Users\fason\AppData\Roaming\Python\Python310\site-packages\coursera_helper\api.py", line 524, in
videos = [VideoV1(resolution, links['mp4VideoUrl'])
KeyError: 'mp4VideoUrl'

@csyezheng
Copy link

@fasonche

What is the course that you are trying to access?
Have you tried downloading other courses and are you getting the same error?
The information you gave is too little. I can't reproduce the same error, so I can't solve the problem.
Tell me how to reproduce this issue, so that you can help me help you.

@fasonche
Copy link

fasonche commented Nov 6, 2023

@csyezheng

I'm very sorry for not being more careful with the instructions.
I retried my old courses, it work great. Thanks so much.
Just do not work on this course: generative-ai-for-everyone
Thank you.

@csyezheng
Copy link

csyezheng commented Nov 6, 2023

@fasonche

This bug has been fixed in version 0.12.2.
Please upgrade coursera-helper by running:

python -m pip install --upgrade --index-url https://pypi.org/simple/ coursera-helper

Make sure you upgrade to the correct version by running:

coursera-helper --version

@fasonche
Copy link

fasonche commented Nov 7, 2023

@csyezheng

I can download it now!
Thank you very much for the help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants