Live data from Hacker News

Yt-dlp: External JavaScript runtime now required for full YouTube support

github.com

281–290 of 646 posts

Re: Yt-dlp: External JavaScript runtime now required for full YouTube support

#281

I remember when QuickTime came out in 1991 and it was obvious to everyone that video should be copied, pasted and saved like any arbitrary data. It's absolutely insane to me how bad the user experience is with video nowadays, even video that's not encumbered by DRM or complex JavaScript clients.

A specific issue with video data is that it’s much denser: the same concept in video takes up more bytes than in text or image. Therefore hosting is more expensive, so less people host and the ones that do (e.g. YouTube) expect revenue. Furthermore, because videos are dense, people want to download them streaming, which means hosts must not just have storage but reliable bandwidth.

Even then, there are a few competitors to YouTube like Nebula, PeerTube, and Odysee. But Nebula requires a subscription and PeerTube and Odysee have worse quality, because good video hosting and streaming is expensive.

Re: Yt-dlp: External JavaScript runtime now required for full YouTube support

#282
post #186

Earlier quoted context omitted.

Glad to hear it’s faster now! YouTube barely works in a full-on browser these days, props to the team that keeps it accessible via a Python script!

Do you use Firefox on Linux, too? 4K Videos freeze so often for me, I don't even try watching them online, and always just download them with yt-dlp. It doesn't bother me enough to give Chrome a try, but maybe that'd make a difference.

I do too use Firefox on Linux, 4K videos seems to work fine for me, but I've never been able to download higher than 1080p with yt-dlp, seems it's just not available without DRM as far as I can tell, so now I'm curious how exactly you've been downloading that?

Re: Yt-dlp: External JavaScript runtime now required for full YouTube support

#283

Seems its already in Arch's repositories, and seems to work, just add another flag to the invocation: yt-dlp --cookies-from-browser firefox --remote-components ejs:github -f "bestvideo[ext=mp4]+bestaudio[ext=m4a]/best[ext=mp4]/best" 'https://www.youtube.com/watch?v=XXX' It is downloading a solver at runtime, took maybe half a second in total, downloads are starting way faster than before it seems to me. [youtube] [js…

What environment are you using that: - Has access to Youtube - Can run Python code - Can’t run JS code If the concern is security, it sounds like the team went to great lengths to ensure the JS was sandboxed (as long as you’re using Deno). If you’re using some sort of weird OS or architecture that Deno/Node doesn’t support, you might consider QuickJS, which is written in pure C and should work on anything. (Although…

[deleted]

Re: Yt-dlp: External JavaScript runtime now required for full YouTube support

#284
post #36

I use yt-dlp (and back then youtube-dl) all the time to archive my liked videos. Started back in around 2010, now I have tens of thousands of videos saved. Storage is cheap and a huge percent of them are not available anymore on the site. I also save temporary videos removed after a time for example NHK honbasho sumo highlights which are only available for a month or so then they permanently remove them.

I was just lamenting last night that we can't watch some of Terutsuyoshi's amazing makuuchi bouts from about three(?) years ago. I wish I'd archived them.

Archive.org has it at least, everything from 2009 until 2023. But that's also need to be mirrored because can be taken down https://archive.org/download/jasons-all-sumo-channel-archive...

Re: Yt-dlp: External JavaScript runtime now required for full YouTube support

#285
post #198
post #84

Earlier quoted context omitted.

I actually do! I have a perpetual VLC playlist which plays those videos randomly if I need some background noise.

How many of the 20,000+ videos you've saved locally do you actually care about if they get "removed" from YouTube?

I'm not sure and that's a good question but after a point it was a principle of saving them rather than caring them about. Probably a digital hoarding attitude.

Re: Yt-dlp: External JavaScript runtime now required for full YouTube support

#286
post #96

Earlier quoted context omitted.

Popular self-hosted solution: https://github.com/tubearchivist/tubearchivist

You people always make everything more complicated than necessary. yt-dlp -o '%(uploader)s/%(upload_date)s - %(title)s [%(id)s].%(ext)s' --cookies-from-browser chrome https://www.youtube.com/playlist?list=LL

> When disagreeing, please reply to the argument instead of calling names. "That is idiotic; 1 + 1 is 2, not 3" can be shortened to "1 + 1 is 2, not 3."

https://news.ycombinator.com/newsguidelines.html

Re: Yt-dlp: External JavaScript runtime now required for full YouTube support

#287

Earlier quoted context omitted.

Youtube is pretty unusable, as they throttle videos, and links sometimes dont work. It has gone downhill fast in recent years.

No idea what you are talking about. I don’t have premium and use in both logged in and logged out.

If I'm logged out, I get "Sign in to confirm you're not a bot" about once a week from both home and the office.

Re: Yt-dlp: External JavaScript runtime now required for full YouTube support

#288

Earlier quoted context omitted.

Plain elements are easy to download, but not great for streaming, which is what most people are doing nowadays. Much of the JS complexity that gets layered on top is to facilitate adaptive bitrate selection and efficient seeking, and the former is especially important for users on crappier internet connections. I'm not a fan of how much JS is required to make all that work though, especially given the vast majority o…

Chrome has finally just landed enabled by default native HLS playback support within the past month. See http://crrev.com/c/7047405 I'm not sure what the rollout status actually is at the moment.

> See go/hls-direct-playback for design and launch stats analysis.

Is that an internal Google wiki or something? I can't find whatever they're referring to.

Re: Yt-dlp: External JavaScript runtime now required for full YouTube support

#289

I remember when QuickTime came out in 1991 and it was obvious to everyone that video should be copied, pasted and saved like any arbitrary data. It's absolutely insane to me how bad the user experience is with video nowadays, even video that's not encumbered by DRM or complex JavaScript clients.

YouTube should have been a distributed p2p system with local storage of your favorite videos. A man can dream...

Re: Yt-dlp: External JavaScript runtime now required for full YouTube support

#290

Earlier quoted context omitted.

Do you use Firefox on Linux, too? 4K Videos freeze so often for me, I don't even try watching them online, and always just download them with yt-dlp. It doesn't bother me enough to give Chrome a try, but maybe that'd make a difference.

I do too use Firefox on Linux, 4K videos seems to work fine for me, but I've never been able to download higher than 1080p with yt-dlp, seems it's just not available without DRM as far as I can tell, so now I'm curious how exactly you've been downloading that?

yt-dlp + 4K works fine for me. The only special thing I remember doing is adding the impersonate feature (which it prompts you to do if it needs it). In other words, instead of `uv tool install yt-dlp`, run `uv tool install yt-dlp[default,curl-cffi]`

The version in the Arch repos does not include the impersonate feature.

Post reply on HN