summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dev-python/dnspython/dnspython-1.16.0-r2.ebuild (renamed from dev-python/dnspython/dnspython-1.16.0-r1.ebuild)9
-rw-r--r--dev-python/dnspython/files/dnspython-1.16.0-py310.patch13
2 files changed, 20 insertions, 2 deletions
diff --git a/dev-python/dnspython/dnspython-1.16.0-r1.ebuild b/dev-python/dnspython/dnspython-1.16.0-r2.ebuild
index 5296e0e643fb..82f4762eb6f5 100644
--- a/dev-python/dnspython/dnspython-1.16.0-r1.ebuild
+++ b/dev-python/dnspython/dnspython-1.16.0-r2.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2020 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
-PYTHON_COMPAT=( python3_{7,8,9} pypy3 )
+PYTHON_COMPAT=( python3_{7..10} pypy3 )
inherit distutils-r1
@@ -23,6 +23,11 @@ RDEPEND="dev-python/pycryptodome[${PYTHON_USEDEP}]
!dev-python/dnspython:py2
!dev-python/dnspython:py3"
+PATCHES=(
+ # Mutable mapping was moved to a different module in 3.10 and removed from the old one
+ "${FILESDIR}"/${P}-py310.patch
+)
+
src_prepare() {
sed -i -e '/network_avail/s:True:False:' \
tests/test_resolver.py || die
diff --git a/dev-python/dnspython/files/dnspython-1.16.0-py310.patch b/dev-python/dnspython/files/dnspython-1.16.0-py310.patch
new file mode 100644
index 000000000000..ad6fa929e5e2
--- /dev/null
+++ b/dev-python/dnspython/files/dnspython-1.16.0-py310.patch
@@ -0,0 +1,13 @@
+diff --git a/dns/namedict.py b/dns/namedict.py
+index 37a1310..7d52668 100644
+--- a/dns/namedict.py
++++ b/dns/namedict.py
+@@ -32,7 +32,7 @@ import dns.name
+ from ._compat import xrange
+
+
+-class NameDict(collections.MutableMapping):
++class NameDict(collections.abc.MutableMapping):
+ """A dictionary whose keys are dns.name.Name objects.
+
+ In addition to being like a regular Python dictionary, this