commit:     a380f8e7ffd21fe5eccbf161aa06f2b12d21b8a0
Author:     Andrew Ammerlaan <andrewammerlaan <AT> gentoo <DOT> org>
AuthorDate: Wed Jun  1 10:35:55 2022 +0000
Commit:     Andrew Ammerlaan <andrewammerlaan <AT> gentoo <DOT> org>
CommitDate: Wed Jun  1 10:55:30 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a380f8e7

dev-python/entrypoint2: enable py3.11

Signed-off-by: Andrew Ammerlaan <andrewammerlaan <AT> gentoo.org>

 dev-python/entrypoint2/entrypoint2-1.0-r1.ebuild   | 29 ++++++++++++++++++++++
 .../files/entrypoint2-1.0-python311.patch          | 13 ++++++++++
 2 files changed, 42 insertions(+)

diff --git a/dev-python/entrypoint2/entrypoint2-1.0-r1.ebuild 
b/dev-python/entrypoint2/entrypoint2-1.0-r1.ebuild
new file mode 100644
index 000000000000..758a23521d24
--- /dev/null
+++ b/dev-python/entrypoint2/entrypoint2-1.0-r1.ebuild
@@ -0,0 +1,29 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=setuptools
+PYTHON_COMPAT=( python3_{8..11} )
+inherit distutils-r1
+
+DESCRIPTION="Easy to use command-line interface for python modules"
+HOMEPAGE="https://github.com/ponty/entrypoint2";
+SRC_URI="https://github.com/ponty/entrypoint2/archive/${PV}.tar.gz -> 
${P}.tar.gz"
+
+LICENSE="BSD-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~x86"
+
+BDEPEND="
+       test? (
+               dev-python/easyprocess[${PYTHON_USEDEP}]
+               dev-python/path-py[${PYTHON_USEDEP}]
+       )
+"
+
+PATCHES=(
+       "${FILESDIR}/${P}-python311.patch"
+)
+
+distutils_enable_tests pytest

diff --git a/dev-python/entrypoint2/files/entrypoint2-1.0-python311.patch 
b/dev-python/entrypoint2/files/entrypoint2-1.0-python311.patch
new file mode 100644
index 000000000000..95de1d3b689a
--- /dev/null
+++ b/dev-python/entrypoint2/files/entrypoint2-1.0-python311.patch
@@ -0,0 +1,13 @@
+diff --git a/entrypoint2/__init__.py b/entrypoint2/__init__.py
+index 63ab78b..a99a298 100644
+--- a/entrypoint2/__init__.py
++++ b/entrypoint2/__init__.py
+@@ -345,7 +345,7 @@ def _correct_args(func, kwargs):
+     Convert a dictionary of arguments including __argv into a list
+     for passing to the function.
+     """
+-    args = inspect.getargspec(func)[0]
++    args = inspect.getfullargspec(func)[0]
+     return [kwargs[arg] for arg in args] + kwargs["__args"]
+ 
+ 

Reply via email to