Valentin-Metz / tum_video_scraper

Download and jumpcut lecture videos from https://live.rbg.tum.de/ and https://tum.cloud.panopto.eu/
55 stars 5 forks source link

Alternative searching for the m3u8 playlists for panopto #6

Closed atticus-sullivan closed 2 years ago

atticus-sullivan commented 2 years ago

Since there are some troubles with the current way we are searching for m3u8 playlists, I implemented a new way depending on the logging of Chrome (should be somewhat comparable with the Networks-tab in the browser developer options).

In the current implementation I simply search for urls ending with .m3u8 and then take the first one of the found urls (could be made interactively, but on the other side when trying to automate the downloading, interaction would be bad). Maybe if this make trouble we need to add some additional constraints to the retrieved urls.

I tested the approach only for panopto, but maybe it is applicable to TumLive as well (and can solve the problems in issue #3). utils.py implements generic url filtering of the retrieved log.

Because I didn't test this extensively, this PR is still WIP (not quite sure if message->params->request->url is the right path through the json log-object, it just works for now). Let's test it on different folders and check if there are any issues.

Valentin-Metz commented 2 years ago

Fixed in the latest version by using a POST request.