commit:     23f3d0c7e76accca65b3a74163015430cc0dcbd1
Author:     Nicolas PARLANT <nicolas.parlant <AT> parhuet <DOT> fr>
AuthorDate: Fri May  2 05:05:02 2025 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sun May  4 06:42:26 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=23f3d0c7

net-dns/knot-resolver: use tomllib instead of toml

update the patch for pytest replacing toml (not packaged), by tomllib.
upstream still allows python3.8, so no issue for now.

Closes: https://bugs.gentoo.org/955202
Signed-off-by: Nicolas PARLANT <nicolas.parlant <AT> parhuet.fr>
Part-of: https://github.com/gentoo/gentoo/pull/41892
Signed-off-by: Sam James <sam <AT> gentoo.org>

 ...i.patch => knot-resolver-6.0.12-pytest_tomllib.patch} | 16 +++++-----------
 net-dns/knot-resolver/knot-resolver-6.0.12.ebuild        |  3 +--
 2 files changed, 6 insertions(+), 13 deletions(-)

diff --git a/net-dns/knot-resolver/files/knot-resolver-6.0.9-pytest_tomli.patch 
b/net-dns/knot-resolver/files/knot-resolver-6.0.12-pytest_tomllib.patch
similarity index 60%
rename from net-dns/knot-resolver/files/knot-resolver-6.0.9-pytest_tomli.patch
rename to net-dns/knot-resolver/files/knot-resolver-6.0.12-pytest_tomllib.patch
index 9e9db90ffe66..143605e4fe11 100644
--- a/net-dns/knot-resolver/files/knot-resolver-6.0.9-pytest_tomli.patch
+++ b/net-dns/knot-resolver/files/knot-resolver-6.0.12-pytest_tomllib.patch
@@ -1,19 +1,13 @@
-From 70d2254de37555167cf60b60d1539ecc9d798fea Mon Sep 17 00:00:00 2001
-From: Nicolas PARLANT <[email protected]>
-Date: Mon, 25 Nov 2024 22:21:07 +0000
-Subject: [PATCH] use tomli instead toml for pytest
-
----
- tests/manager/test_knot_resolver_manager.py | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
+https://bugs.gentoo.org/955202
+toml is not packaged, use tomllib instead
+upstream still allows python3.8, so no issue for now
 diff --git a/tests/manager/test_knot_resolver_manager.py 
b/tests/manager/test_knot_resolver_manager.py
 index 05d0e61d..b45c79a4 100644
 --- a/tests/manager/test_knot_resolver_manager.py
 +++ b/tests/manager/test_knot_resolver_manager.py
 @@ -1,11 +1,11 @@
 -import toml
-+import tomli
++import tomllib
  
  from knot_resolver import __version__
  
@@ -22,7 +16,7 @@ index 05d0e61d..b45c79a4 100644
 -    with open("pyproject.toml", "r") as f:
 -        pyproject = toml.load(f)
 +    with open("pyproject.toml", "rb") as f:
-+        pyproject = tomli.load(f)
++        pyproject = tomllib.load(f)
  
      version = pyproject["tool"]["poetry"]["version"]
      assert __version__ == version

diff --git a/net-dns/knot-resolver/knot-resolver-6.0.12.ebuild 
b/net-dns/knot-resolver/knot-resolver-6.0.12.ebuild
index 6ec43c7c0ad6..f57391afdbcb 100644
--- a/net-dns/knot-resolver/knot-resolver-6.0.12.ebuild
+++ b/net-dns/knot-resolver/knot-resolver-6.0.12.ebuild
@@ -65,7 +65,6 @@ DEPEND="
                        $(python_gen_cond_dep '
                                dev-python/pyparsing[${PYTHON_USEDEP}]
                                dev-python/pytest-asyncio[${PYTHON_USEDEP}]
-                               dev-python/tomli[${PYTHON_USEDEP}]
                        ')
                )
        )
@@ -86,7 +85,7 @@ PATCHES=(
        "${FILESDIR}"/${PN}-5.5.3-nghttp-openssl.patch
        "${FILESDIR}"/${PN}-6.0.9-libsystemd.patch
        "${FILESDIR}"/${PN}-6.0.9-config-example.patch
-       "${FILESDIR}"/${PN}-6.0.9-pytest_tomli.patch
+       "${FILESDIR}"/${PN}-6.0.12-pytest_tomllib.patch
 )
 
 pkg_setup() {

Reply via email to