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
132k stars 10.01k forks source link

webtv.senato.it #29109

Open frafra opened 3 years ago

frafra commented 3 years ago

Checklist

Example URLs

Description

The video is segmented and loaded via JavaScript using jwplayer. Look for the script tag with id video_playlist. It contains a line like this: playlist: "https://prd-senato.spectar.tv/canale/assemblea/legislatura/18/seduta/329/formato/flvplayer/quality/hq". There is an XML file containing a playlist with multiple videos, in different formats.

SuperSonicHub1 commented 3 years ago

@frafra The playlist seems to be a JWPlayer XML playlist. I'm having issues finding documentation at the moment and youtube-dl sadly lacks a parser as part of its standard library. JWPlayer is currently under a non-commercial Creative Commons license, which clashes with the Unlicense, meaning I can't use their code, and I'm struggling to find when JWPlayer was still under an open-source license. I'll see what I can do tomorrow.

SuperSonicHub1 commented 3 years ago

@frafra I've ultimately decided that I'm going to poorly parse the XML myself in order for us to get what we really want: those juicy HLS playlists. Before I go any further, can I have some more example URLs so that I can make sure I parse the URLs correctly?

frafra commented 3 years ago

Sure! Here are some other links:

rautamiekka commented 3 years ago

IIRC ytdl already uses XML (or at least HTML) parsing through stock modules, so you won't need to poorly parse it, and it's hugely discouraged to even try to.

SuperSonicHub1 commented 3 years ago

@rautamiekka

IIRC ytdl already uses XML (or at least HTML) parsing through stock modules, so you won't need to poorly parse it, and it's hugely discouraged to even try to.

I know, I was more talking about how I'm going to take a lot of shortcuts in parsing the data structure itself and make a lot of assumptions compared to an official JWPlayer parser.

amreo commented 2 years ago

Is issue still open?