Giter VIP home page Giter VIP logo

Comments (23)

C0D3D3V avatar C0D3D3V commented on June 20, 2024 1

The problem is not the downloading of the videos itself. This should be relatively easy to implement. The real problem is that the downloader cannot get the data from the video. The link of the video would be important, but because Kaltura is not supported by the Moodle app, there is no easy way to get the link.

I am already working on a solution. The Moodle Downloader-2 uses the Moodle API, so there is no easy way to get the link. However, I'm working on a way to generate a Moodle browser cookie that would allow you to access pages that are not supported by the API, and thus get the link for the Kultura video.

This is unnecessarily complicated and would be easier to implement if you didn't use the Moodle API. My old Moodle downloader does not have a maintainer, but it would be easier to implement there.

I'll share my progress here, probably I'll get a lot further today.

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024 1

At this point this is now only a problem of Youtube-dl. Kaltura is basically supported by Youtube-dl (https://github.com/ytdl-org/youtube-dl/blob/master/docs/supportedsites.md) but not the Moodle plugin Kalvidre. If I have free time I can write a plugin for youtube-dl, so that it is supported too.

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024

Downloading the HTML files on which the videos are displayed should not be very difficult.
Can you please try changing line 88 in /moodle_connector/results_handler.py from:

 if (module_modname in ["resource", "folder", "url", "page"]):

to:

 if (module_modname in ["resource", "folder", "url", "page", "kalvidres"]):

To download the actual videos I have to think about more. I'll take a closer look at it after the exams.

from moodle-dl.

artaeun avatar artaeun commented on June 20, 2024

no html files are downloaded in the folder of the courses which have videos uploaded on moodle.

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024

I tried to set up kaltura in my own Moodle, but that was not possible. Kaltura is completely commercial. So we need to sit down together again so I can gather more information.

from moodle-dl.

sononicola avatar sononicola commented on June 20, 2024

Hi
There is something I can do to help you to add this feature? In my university all video are uploaded in Kultura. I'm not a developer but if you tell me what links/xpaths you need I'll try to give you

from moodle-dl.

sononicola avatar sononicola commented on June 20, 2024

For downloding videos:
I'm in the page where the video is, then clicked with right click and opened only the video in a new tab (the firefox function), then in the console: Imgur
Opening the second link and right clicking: there is the "save video" option. Pasting these links in jdownloader it's very fast.
Only thing is I don't know where the setting for video quality bitrate is. I remember some months ago it was there. @C0D3D3V

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024

All Commits in the branch issue-41 are related to this issue. I will only tag important commits (milestones) specifically to this issue.

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024

It is now possible to generate the browser cookie. There is not much missing and hopefully it should be possible to download the videos soon.

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024

I need your help now. Could one of you please download the latest version of the Issue-41 branch (from here https://github.com/C0D3D3V/Moodle-Downloader-2/archive/issue-41.zip), preferably parallel to your current installation, so don't replace it, just copy your config.json and moodle_state.db to a new test folder...

Then execute the main.py with the --log-responses option. This creates a file called responses.log in the folder. You can stop the downloader with [Ctr+C] as soon as it starts downloading files (so as soon as the many percentage numbers are displayed) or wait till it is finished, in both cases nothing more will change in the responses.log file. This file can contain private information, so it is best to send it to me by mail.

I need this file so I know exactly what the JSON structure looks like.

from moodle-dl.

sononicola avatar sononicola commented on June 20, 2024

yeah sure. I'm having some trouble getting a new token (the old one expired). In our moodle site doesn't work the automatic method and the moodle-app method (this because it launch a new page of our university login. In android works the app, but in the moodle Demo not).

I remember last time I used the sso login with the console-method but for some reason this time there is not a moodlemobile://token=$apptoken in console.

Anyway: send me your mail address or telegram username to send the log

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024

telegram username: c0d3d3v

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024

We can also have a look at the soo process together, maybe we get an idea how to fix the token obtaining process.

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024

Ok, we are ready for a test! Make sure you also set a privatetoken in the config.json, you can do this by running python main.py --new-token --sso or by doing it manually, the privatetoken is the part after the second ::::. Set it in the config like this (don't forget the comma):

    "privatetoken": "8RpHJevJ42W7QN23OMkeYcdOYw3YfWgWGKsak7WB3Z88wcApSCVZ9TgY6M5fEO1m",

Use the issue-41 branche (https://github.com/C0D3D3V/Moodle-Downloader-2/archive/issue-41.zip)

from moodle-dl.

k4j3d3v avatar k4j3d3v commented on June 20, 2024

Hi,
It would be very cool to support download of bbcollaborate video(lessons).
For now it doesn't seem to work, because where there are links to bbcollaborate recorded lesson it downloads related html pages.
Also an interesting thing is that it downloads together .desktop files with a public url for the videolectures.
So i solved the issue by making a very simple script using the urls contained in these files.
But i think that to add direct support for that will not be so hard.

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024

Yes we can try to implement that... Exactly for something like this I have prepared the architecture :D
I just need more information, but more about that later. I'll get back to you in a week (as soon as I have time again). Then I'll ask again for the information I need.

from moodle-dl.

k4j3d3v avatar k4j3d3v commented on June 20, 2024

Wonderful!
Let me know if i can do something meanwhile :)

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024

In order to write an extractor, I need access to a Moodle with Kaltura. If someone is still interested in an extractor for Kultura videos, he should contact me, we can work together via Discord and implement the extractor in no time.

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024

or someone sends me the source codes of all the websites involved. Starting with the /mod/kalvidres/view.php page.

This is how you see the source code: https://developer.mozilla.org/en-US/docs/Tools/View_source

from moodle-dl.

nsomaru avatar nsomaru commented on June 20, 2024

Hi @C0D3D3V,

I'm interested in helping. Please clarify what you mean by "the source code for all the websites involved" and where you would like them to be sent?

Thanks.

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024

very good, can we talk over Discord? My username is c0d3d3v#8812

I probably won't have time until Wednesday, but you can add me already.

I can then guide you in a conversation so we can gather the necessary information together.

Have you already installed vscode, that is not necessary, but then we could also directly make some tests if it works.

from moodle-dl.

C0D3D3V avatar C0D3D3V commented on June 20, 2024

@nsomaru I can also explain to you here what kind of information I need if you don't like to talk over Discord.

First, on your Moodle, open any Kaltura video so that in the URL in the URL bar contains "/mod/kalvidres/view.php" .
Then press [Ctrl + U] and send me the source code, which you can then see. You can send it to me by email or here.

from moodle-dl.

nsomaru avatar nsomaru commented on June 20, 2024

sorry for the delay, was in an exam period. Have sent you the file over email (on your profile) as I didn't want to share the HTML publicly here.

from moodle-dl.

Related Issues (20)

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.