Solved deno

Today I did pkg upgrade and installed .
www/deno, py311-yt-dlp-ejs and update yt-dlp.
I did try delete deno bit it want remove mpv, yy-dlp and py311-yt-delp-ejs. Looks like that mpv also need it deno now.
 
Okay. MPV needs yt-dlp and yt-dlp...and I have two new packages and BTW "deno" doesn't have maintainer and supposed to be soon removed...
 
For yt-dlp I did also try to use the deno package to no avail. So I tried node also to no avail. I also tried to build each from ports. I recall one failed and the other I stopped caring mid way through because it was taking so long, sort of like how I won't build chromium anymore. Life's too short. I'd rather stop using youtube.
 
I did try delete deno
And why would you do that? When pkg pulls in a dependency, it's because the software needs it to run properly.
The deno requirement has been the case for a few weeks now and yt-dlp has been warning about it a few months back already. Recent changes on YouTube made this necessary: it now requires solving "JavaScript challenges" and Deno (a play on Node.js) is a JavaScript runtime that helps yt-dlp do just that.

Okay. MPV needs yt-dlp and yt-dlp...and I have two new packages
mpv can play from YouTube using yt-dlp. So mpv depends on yt-dlp, which depends on py-yt-dlp-ejs, which in turn depends on Deno.

BTW "deno" doesn't have maintainer and supposed to be soon removed...
Personally I would've preferred lang/quickjs or lang/quickjs-ng as default because they're lighter and are currently still maintained in FreeBSD, but they have their own issues and Deno is yt-dlp's default anyway, so ...
By the way, you can use them instead of Deno if you want simply by pointing to their binaries in yt-dlp's config file.
 
Yes, I added --js-runtimes to the config. No, it never worked works. I don't know what special sauce deno or node brings to the table that openjdk-jre does not but it must something special as they're tremendous.
 
OpenJDK JRE is a *Java* runtime environment. Deno and Node.js are *JavaScript* runtime environments. Apples and engine parts.

yt-dlp can use the following runtimes: Deno (default), Node.js, Bun and QuickJS.

Are all your ports/packages up to date? Maybe you have an outdated version of yt-dlp. If you already have these lines
Code:
--js-runtimes deno:/usr/local/bin/deno
--remote-components ejs:github
in ~/.config/yt-dlp/config, then run:
$ cd /tmp
$ fetch https://github.com/yt-dlp/yt-dlp/archive/refs/heads/master.zip
$ unzip master.zip
$ /usr/local/bin/python3 /tmp/yt-dlp-master/yt_dlp/__main__.py -f18 https://www.youtube.com/shorts/sI24hdszcXY
(if you don't have the /usr/local/bin/python3 symlink, replace it with any /usr/local/bin/python3* you have available, e.g. python3.11)

What does yt-dlp say?
 
What does yt-dlp say?
Code:
$ /usr/local/bin/python3 /tmp/yt-dlp-master/yt_dlp/__main__.py -f18 https://www.youtube.com/shorts/sI24hdszcXY
[youtube] Extracting URL: https://www.youtube.com/shorts/sI24hdszcXY
[youtube] sI24hdszcXY: Downloading webpage
WARNING: [youtube] No supported JavaScript runtime could be found. Only deno is enabled by default; to use another runtime add  --js-runtimes RUNTIME[:PATH]  to your command/config. YouTube extraction without a JS runtime has been deprecated, and some formats may be missing. See  https://github.com/yt-dlp/yt-dlp/wiki/EJS  for details on installing one
[youtube] sI24hdszcXY: Downloading android vr player API JSON
[info] sI24hdszcXY: Downloading 1 format(s): 18
[info] There are no subtitles for the requested languages
[download] Destination: Day 1 at Scale 23X - One Word to Describe FreeBSD [sI24hdszcXY].mp4
[download] 100% of    2.09MiB in 00:00:01 at 2.08MiB/s
[EmbedSubtitle] There aren't any subtitles to embed

Also,
Code:
htpc:/tmp $ deno
ld-elf.so.1: /usr/local/bin/deno: Undefined symbol "_ZNSt3__122__libcpp_verbose_abortEPKcz"

This is with deno from packages. Thus the attempt to build deno from ports and then to build node from ports, with appropriate change in the yt-dlp config.
 
roper, it's obvious now that the problem is not with yt-dlp or its configuration, but with deno not being able to run.

You may be running programs built for a different version of FreeBSD, causing an ABI mismatch. What FreeBSD version are you using ( freebsd-version -kru)?
 
roper, it's obvious now that the problem is not with yt-dlp or its configuration, but with deno not being able to run.

You may be running programs built for a different version of FreeBSD, causing an ABI mismatch. What FreeBSD version are you using ( freebsd-version -kru)?
Yes, you're probably right. However, I'm not enthusiastic about fixing that at the moment. Fernandel has the thread marked solved so it's all good. Thanks!
 
Back
Top