commit:     9cc48229123637818ae4c7b39c987c2eb26a6b69
Author:     Arthur Zamarin <arthurzam <AT> gentoo <DOT> org>
AuthorDate: Tue Jun  6 17:39:17 2023 +0000
Commit:     Arthur Zamarin <arthurzam <AT> gentoo <DOT> org>
CommitDate: Tue Jun  6 17:39:17 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9cc48229

dev-python/pydiffx: enable py3.12

Signed-off-by: Arthur Zamarin <arthurzam <AT> gentoo.org>

 dev-python/pydiffx/files/pydiffx-1.1-fix-py3.12.patch | 14 ++++++++++++++
 dev-python/pydiffx/pydiffx-1.1.ebuild                 |  6 +++++-
 2 files changed, 19 insertions(+), 1 deletion(-)

diff --git a/dev-python/pydiffx/files/pydiffx-1.1-fix-py3.12.patch 
b/dev-python/pydiffx/files/pydiffx-1.1-fix-py3.12.patch
new file mode 100644
index 000000000000..1be51cdb6c93
--- /dev/null
+++ b/dev-python/pydiffx/files/pydiffx-1.1-fix-py3.12.patch
@@ -0,0 +1,14 @@
+https://github.com/beanbaginc/diffx/pull/5
+From: Arthur Zamarin <arthur...@gentoo.org>
+Date: Tue, 6 Jun 2023 20:32:44 +0300
+Subject: [PATCH] fix usage of deprecated assertRaisesRegex
+
+--- a/pydiffx/tests/testcases.py
++++ b/pydiffx/tests/testcases.py
+@@ -65,5 +65,5 @@ def assertMultiLineBytesEqual(self, first, second, 
line_endings='unix'):
+
+     @contextmanager
+     def assertRaisesMessage(self, exception, message):
+-        with self.assertRaisesRegexp(exception, re.escape(message)):
++        with self.assertRaises(exception, msg=message):
+             yield

diff --git a/dev-python/pydiffx/pydiffx-1.1.ebuild 
b/dev-python/pydiffx/pydiffx-1.1.ebuild
index ec079b0ec93f..c35d375a1651 100644
--- a/dev-python/pydiffx/pydiffx-1.1.ebuild
+++ b/dev-python/pydiffx/pydiffx-1.1.ebuild
@@ -4,7 +4,7 @@
 EAPI=8
 
 DISTUTILS_USE_PEP517=setuptools
-PYTHON_COMPAT=( python3_{9..11} )
+PYTHON_COMPAT=( python3_{10..12} )
 
 inherit distutils-r1
 
@@ -34,6 +34,10 @@ BDEPEND="
        )
 "
 
+PATCHES=(
+       "${FILESDIR}"/${P}-fix-py3.12.patch
+)
+
 distutils_enable_tests unittest
 
 src_prepare() {

Reply via email to