commit:     71862b648755ece007d49c3cc21dac1b527e03c8
Author:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
AuthorDate: Thu Jan 29 19:48:35 2026 +0000
Commit:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
CommitDate: Thu Jan 29 20:03:42 2026 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=71862b64

dev-python/yt-dlp-ejs: add 0.4.0

Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org>

 dev-python/yt-dlp-ejs/Manifest                |  2 ++
 dev-python/yt-dlp-ejs/yt-dlp-ejs-0.4.0.ebuild | 37 +++++++++++++++++++++++++++
 2 files changed, 39 insertions(+)

diff --git a/dev-python/yt-dlp-ejs/Manifest b/dev-python/yt-dlp-ejs/Manifest
index dfa89a1f16ce..a73495cbc8dd 100644
--- a/dev-python/yt-dlp-ejs/Manifest
+++ b/dev-python/yt-dlp-ejs/Manifest
@@ -1,2 +1,4 @@
 DIST yt_dlp_ejs-0.3.2-py3-none-any.whl.zip 53252 BLAKE2B 
8acedb96906b52b4d2befc592b2ae96d814bda0a93d02d244e563506e8a648cdd2cf45d3ff57823553b7fb2af419634ab6e8441b7f8ea8b95b10d036b4d0de9e
 SHA512 
b904143b0bbd0d75ba167d26b163ae1680a1658d95d69065eda16d3adab547d230ab453f0d7562948ec100313d0289c3f971e4712dc14df24c8a5d5c0529ede2
 DIST yt_dlp_ejs-0.3.2.tar.gz 34678 BLAKE2B 
c2d21f084fb6e8127552dbbfd08f951781a42fcfd7c0b22779f5c31e936d0e51989f765a721c2ae527eb01eb241966a45aa1295f5708675c18365b4bc3dbc51b
 SHA512 
75b71ed5f9e9eddd972fd44d674a9dcc8606d5939ab467fa0df7532bfd9cc48277fa69656012f17e958914ad3220f99ec047c3cba3dfff15019125ffa5d02d1b
+DIST yt_dlp_ejs-0.4.0-py3-none-any.whl.zip 53600 BLAKE2B 
3857fde19e6d186668817c7c15a591387b1959a5e848e499be5f41d911e2feea0fc745ce91abc4c4fc074e3345354cd797799da2b7621292aff5e7504994569c
 SHA512 
b36118a87f5da0877949abc13f1e1c339168fbf8994912ada0e73f4ba369d4f1cd6b1916a7d684ea9b872620bcec652272c8c021c70b6af12faa912b7bab1d89
+DIST yt_dlp_ejs-0.4.0.tar.gz 96768 BLAKE2B 
21e74c61a1aa1f39ae309aca2679a84598900cc0f835b3f8b61680c4cb79f69da39827e3b6bd08c36c8a9cdae9da41ea48b674f7654473cb645648de3b012555
 SHA512 
6282ce4d014339ede98d8332c6d5d344bed7911ecaa395a30ee36a2607977af179c25262a558a4b1299b27a5c511e1b4082fe6ba57eb8b86525d59cd85b5c201

diff --git a/dev-python/yt-dlp-ejs/yt-dlp-ejs-0.4.0.ebuild 
b/dev-python/yt-dlp-ejs/yt-dlp-ejs-0.4.0.ebuild
new file mode 100644
index 000000000000..f21c67dcb2e7
--- /dev/null
+++ b/dev-python/yt-dlp-ejs/yt-dlp-ejs-0.4.0.ebuild
@@ -0,0 +1,37 @@
+# Copyright 2025-2026 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=hatchling
+PYTHON_COMPAT=( pypy3_11 python3_{11..14} )
+inherit distutils-r1 pypi
+
+DESCRIPTION="External JavaScript for yt-dlp supporting many runtimes"
+HOMEPAGE="https://github.com/yt-dlp/ejs/";
+# wheel for .js files, github's assets also has them but uncompressed
+SRC_URI+=" $(pypi_wheel_url --unpack)"
+
+LICENSE="Unlicense"
+LICENSE+=" ISC MIT" # .js dependencies
+SLOT="0"
+# bumps should typically be done straight-to-stable like yt-dlp itself
+KEYWORDS="amd64 arm arm64 ~hppa ppc ppc64 ~riscv x86 ~arm64-macos ~x64-macos"
+
+BDEPEND="
+       app-arch/unzip
+       dev-python/hatch-vcs[${PYTHON_USEDEP}]
+"
+
+# this only tests basic python bits without javascript to avoid headaches
+distutils_enable_tests unittest
+
+src_prepare() {
+       distutils-r1_src_prepare
+
+       # drop deno/npm calls and use pre-generated .js instead, this
+       # both prevents network use and ensures no hash mismatch given
+       # yt-dlp checks the sha512sum of the .js files
+       sed -i '/wheel.hooks.custom/,/^$/d' pyproject.toml || die
+       mv ../yt_dlp_ejs/yt/solver/*.js yt_dlp_ejs/yt/solver/ || die
+}

Reply via email to