Live data from Hacker News

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

github.com

311–320 of 646 posts

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

#311
post #270

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…

I totally agree. And much of the JS complexity on smaller niche video sites aren’t even implemented properly. On some sites I just open developer console, find the m3u8 file URL and cookies in the request, and download it to view locally. Browsers generally do allow native seeking if the video is properly encoded and the site supports such niceties as Accept-Range: bytes.

[deleted]

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

#312

Earlier quoted context omitted.

> 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. The video experience for typical video files is great these days compared to the past. I think you may be viewing the past through rose colored glasses. For years it was a pain to deal with video because you had to navigate third party players (remember Real Player?…

Local video could be a nightmare in 90s. I remember those days. I remember when it was revolutionary that the Microsoft Media Player came out, and you could use one player for several formats, rather than each video format requiring its own (often buggy) player. Getting the right codecs was still a chore, though. MS Media Player eventually fell behind the curve, but eventually we got VLC and things got great.

> MS Media Player eventually fell behind the curve, but eventually we got VLC and things got great.

And in-between those we had Media Player Classic together with the Combined Community Codec Pack, and once you had MPC + CCCP installed, you could finally view those glorious aXXo-branded 700MB files found on a random DC++ hub.

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

#313

Earlier quoted context omitted.

> 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. The video experience for typical video files is great these days compared to the past. I think you may be viewing the past through rose colored glasses. For years it was a pain to deal with video because you had to navigate third party players (remember Real Player?…

That's if you weren't using a Mac

Ah man, Macs of yore could play .rm/.rv files natively?

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

#314

Earlier quoted context omitted.

Could you elaborate on why? It seems to me that YouTube's implicit contract with the user is "these people paid us to show you this advert", not "we vouch for the integrity and veracity of this advert". I obviously agree that it'd be nice if YouTube would put more effort into screening adverts, but I don't see why they're _obligated_ to. I'm happy to be corrected, though.

Because taking money from a con artist to deliver marks based on profiles you've collected on everyone to see who's most likely to be taken in makes you an accessory if not accomplice to fraud. Businesses (in particular the literal biggest ad agency in the world) should know who they are partnering with. Not vetting the people they're allowing to place ads is at best negligent. The fact that the FBI warns people to u…

That's a fair point. Thanks for the detailed response.

I'm curious as to what the scam ads you mention actually are. I use an adblocker most of the time, and most of the adverts that I do see are annoying but fairly innocuous. Furniture, insurance, charter schools, social media apps, shitty mobile games, et cetera. I've seen plenty of slightly scummy adverts, but I can't recall seeing many that are really harmful or blatantly fraudulent. I'm curious to hear what adverts other people are seeing that are so outrageous.

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

#315

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…

> Although it will be a lot slower, I’m not clear just how slow.

Around 30-50x slower than V8 (node/deno).

I've been recently benchmarking a lot of different engines: https://ivankra.github.io/javascript-zoo/

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

#316
post #265

Earlier quoted context omitted.

What you’re describing with QuickTime was a proprietary nightmare that didn’t even work correctly across Apple products, let alone Microsoft or Linux. Today with modern tools like VLC or MPV and ffmpeg nearly anything can be viewed, streamed, or locally saved by your average user with basic Google search skills. And the number of free and paid video editing tools as far beyond what we ever had in the past. Then there…

One issue GP may be referring to is the bifurcation of video viewing tools and video editing tools. There are excellent video editing tools: on the desktop from paid ones like Premiere to free (as in beer) ones like DaVinci Resolve, not to mention mobile apps behind the TikTok culture. There are also excellent and built-in video players in every browser and every OS. But in the modern age viewing and editing a video…

I think that happens when the rift between producers and consumers require some learning to jump from one to the other, at least professionally.

Some of the people who produce videos for a living require vastly different tools than someone who needs to trim the edges of a short home video clip, so the the UI and UX has to be different, otherwise these people won't be able to effectively do their job.

For writing, everyone pretty much does it the same way. You sit down, you enter characters with a keyboard, and sometimes to remove/edit stuff. Of course, there are professional tools for people who write stories for a living, that helps you keep track of arcs, characters, environments and so on, and many professionals do use them.

So while it looks like "Ah, Word actually works for everyone, why can't we do the same for video?" there are still professionals who need tools specifically for "writing stories" or "writing screenplays", and same in other areas :)

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

#317

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…

It was just updated again today, and at least for me, when you install it using the package name "yt-dlp[default]", it already downloads both deno and the solver automatically.

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

#318
post #129

Just one question. I see all these 3rd party clients solving the problem separately. Isn't it easier for everyone to build a unified decoder backend that exposes a stable and consistent interface for all the frontends? That way, it will get more attention and each modification will have to be done only once. Since JS is the big issue here, the backend itself could be written in JS, TS or something else that compiles…

Alternatively, I'm not sure if this might be an impetus to move the bulk of the codebase itself to TS/JS and just use Deno/Node/Bun or otherwise to move to Rust with rusty_v8 or deno_core directly.

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

#319

Earlier quoted context omitted.

What you’re describing with QuickTime was a proprietary nightmare that didn’t even work correctly across Apple products, let alone Microsoft or Linux. Today with modern tools like VLC or MPV and ffmpeg nearly anything can be viewed, streamed, or locally saved by your average user with basic Google search skills. And the number of free and paid video editing tools as far beyond what we ever had in the past. Then there…

Modern video tools provide an enormous selection, much of which is free. But I'll always miss VirtualDub.

> But I'll always miss VirtualDub.

Miss? I still used it just last week! Still haven't found anything that is as fast and easy to take a directory of frames in .png and concatenating them together into a proper video. I use it post 3D renders all the time :)

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

#320
post #237

Earlier quoted context omitted.

I use YouTube daily in safari and edge, this is complete hyperbole.

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

No issues here for me with uBO, logged in or not, no premium
Post reply on HN