commit:     7b682bc3961e1204555fb5b709315058692d6481
Author:     Arthur Zamarin <arthurzam <AT> gentoo <DOT> org>
AuthorDate: Wed Aug 18 15:04:11 2021 +0000
Commit:     Arthur Zamarin <arthurzam <AT> gentoo <DOT> org>
CommitDate: Wed Aug 18 15:04:11 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7b682bc3

dev-python/slixmpp: enable py3.10 with patch

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

 .../slixmpp/files/slixmpp-1.7.1-fix-py3.10.patch   | 28 ++++++++++++++++++++++
 dev-python/slixmpp/slixmpp-1.7.1.ebuild            | 10 ++++----
 dev-python/slixmpp/slixmpp-9999.ebuild             |  6 +----
 3 files changed, 34 insertions(+), 10 deletions(-)

diff --git a/dev-python/slixmpp/files/slixmpp-1.7.1-fix-py3.10.patch 
b/dev-python/slixmpp/files/slixmpp-1.7.1-fix-py3.10.patch
new file mode 100644
index 00000000000..0901090e465
--- /dev/null
+++ b/dev-python/slixmpp/files/slixmpp-1.7.1-fix-py3.10.patch
@@ -0,0 +1,28 @@
+From 8b7648502b003d433a08333b041baf1d4960c9d4 Mon Sep 17 00:00:00 2001
+From: Nicolas Cedilnik <nic...@nicoco.fr>
+Date: Mon, 22 Feb 2021 13:07:15 +0100
+Subject: [PATCH] Fix deprecation warning
+
+---
+ slixmpp/thirdparty/orderedset.py | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/slixmpp/thirdparty/orderedset.py 
b/slixmpp/thirdparty/orderedset.py
+index f6642db3..43023af4 100644
+--- a/slixmpp/thirdparty/orderedset.py
++++ b/slixmpp/thirdparty/orderedset.py
+@@ -20,9 +20,9 @@
+ #     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ #     OTHER DEALINGS IN THE SOFTWARE.
+ 
+-import collections
++from collections.abc import MutableSet
+ 
+-class OrderedSet(collections.MutableSet):
++class OrderedSet(MutableSet):
+ 
+     def __init__(self, iterable=None):
+         self.end = end = []
+-- 
+GitLab
+

diff --git a/dev-python/slixmpp/slixmpp-1.7.1.ebuild 
b/dev-python/slixmpp/slixmpp-1.7.1.ebuild
index 19974e84095..e37f059d7d3 100644
--- a/dev-python/slixmpp/slixmpp-1.7.1.ebuild
+++ b/dev-python/slixmpp/slixmpp-1.7.1.ebuild
@@ -3,7 +3,7 @@
 
 EAPI=7
 
-PYTHON_COMPAT=( python3_{7..9} )
+PYTHON_COMPAT=( python3_{8..10} )
 
 inherit distutils-r1
 
@@ -31,8 +31,8 @@ RDEPEND="
        ${DEPEND}
 "
 
-distutils_enable_tests unittest
+PATCHES=(
+       "${FILESDIR}/${P}-fix-py3.10.patch"
+)
 
-python_test() {
-       "${EPYTHON}" ./run_tests.py || die "Tests failed with ${EPYTHON}"
-}
+distutils_enable_tests unittest

diff --git a/dev-python/slixmpp/slixmpp-9999.ebuild 
b/dev-python/slixmpp/slixmpp-9999.ebuild
index 0f5e88aa5f6..4c7eb16a1e1 100644
--- a/dev-python/slixmpp/slixmpp-9999.ebuild
+++ b/dev-python/slixmpp/slixmpp-9999.ebuild
@@ -3,7 +3,7 @@
 
 EAPI=7
 
-PYTHON_COMPAT=( python3_{7..9} )
+PYTHON_COMPAT=( python3_{8..10} )
 
 inherit distutils-r1
 
@@ -32,7 +32,3 @@ RDEPEND="
 "
 
 distutils_enable_tests unittest
-
-python_test() {
-       "${EPYTHON}" ./run_tests.py || die "Tests failed with ${EPYTHON}"
-}

Reply via email to