1 |
commit: c09787924e5272f8d6f453c274d5a6dac0904b19 |
2 |
Author: Michał Górny <mgorny <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed May 13 10:23:12 2020 +0000 |
4 |
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed May 13 11:33:15 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c0978792 |
7 |
|
8 |
dev-python/setuptools: Bump to 46.2.0 |
9 |
|
10 |
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> |
11 |
|
12 |
dev-python/setuptools/Manifest | 1 + |
13 |
.../files/setuptools-46.2.0-test-warning.patch | 82 ++++++++++++++++++++++ |
14 |
dev-python/setuptools/setuptools-46.2.0.ebuild | 70 ++++++++++++++++++ |
15 |
3 files changed, 153 insertions(+) |
16 |
|
17 |
diff --git a/dev-python/setuptools/Manifest b/dev-python/setuptools/Manifest |
18 |
index 07364d4167c..86718e07171 100644 |
19 |
--- a/dev-python/setuptools/Manifest |
20 |
+++ b/dev-python/setuptools/Manifest |
21 |
@@ -1,3 +1,4 @@ |
22 |
DIST setuptools-44.0.0.zip 858893 BLAKE2B 02ba2a838487ba9e80d9ca3b8598cecbec4d286f2734be439d2b73f3f7f0ca80e80ea71a0c2322093deb548503c82d6eb32b1585992979b053f14f49baa00baa SHA512 bb48e7763d258e654472bc416d16ec8708eefa95d1eb03cb6e81b623fd636cefc51a0bd67887084ab0214e256e2030a8f655184c3b59ad6937abab6a6178f3a1 |
23 |
DIST setuptools-44.1.0.zip 858569 BLAKE2B f59f154e121502a731e51294ccd293d60ffccadacf51e23b53bf7ceba38858948b86783238061136c827ac3373ea7ea8e6253d4bb53f3f1dd69284568ec65a68 SHA512 4dfb0f42d334b835758e865a26ecd1e725711fa2b9c38ddc273b8b3849fba04527bc97436d11ba1e98f1a42922aa0f0b9032e32998273c705fac6e10735eacbf |
24 |
DIST setuptools-46.1.3.zip 862431 BLAKE2B 89d65360e15b22f535312627723ad61df84dce3ee9d5850dd0c60dace0f8c04a502ac6246afe1add1e4fbd0e0dc9530afc8bfd2a4cf058f93cde2ff4184e21f2 SHA512 7f8f99313ce2af2cbfa86ff9a3135bc3445804e9323a375b498d20dad7f8fc819481da0c2a057160397e98b6178c1eb453a093652cfdfe7896c9d31732f7ad8c |
25 |
+DIST setuptools-46.2.0.zip 865117 BLAKE2B 490387146003e07a5391afa798d1e45a76e9afc81c3e0c484005b3b0bff15f172db2016907199fe2216a4e17379987a53d58149d285be6dcfe7c37a64ce7c359 SHA512 d8d89a99c6a3be0a343d6a0e17117ba00393188d69c8995a5dbe9a7772c002fc301a53963288231e3f8053ffda4cafd5406edb2f4650f2036c665f8e3eb5822e |
26 |
|
27 |
diff --git a/dev-python/setuptools/files/setuptools-46.2.0-test-warning.patch b/dev-python/setuptools/files/setuptools-46.2.0-test-warning.patch |
28 |
new file mode 100644 |
29 |
index 00000000000..e27db9a41da |
30 |
--- /dev/null |
31 |
+++ b/dev-python/setuptools/files/setuptools-46.2.0-test-warning.patch |
32 |
@@ -0,0 +1,82 @@ |
33 |
+From 56bcce894e99059a8abda29d8b919b0bee7fd1b9 Mon Sep 17 00:00:00 2001 |
34 |
+From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= <miro@×××××××.cz> |
35 |
+Date: Tue, 12 May 2020 13:33:04 +0200 |
36 |
+Subject: [PATCH] Reuse @ack_2to3 in TestDevelop.test_2to3_user_mode |
37 |
+ |
38 |
+Fixes https://github.com/pypa/setuptools/issues/2100 |
39 |
+--- |
40 |
+ changelog.d/2105.misc.rst | 1 + |
41 |
+ setuptools/tests/__init__.py | 4 +++- |
42 |
+ setuptools/tests/test_develop.py | 2 ++ |
43 |
+ setuptools/tests/test_test.py | 4 +--- |
44 |
+ 4 files changed, 7 insertions(+), 4 deletions(-) |
45 |
+ create mode 100644 changelog.d/2105.misc.rst |
46 |
+ |
47 |
+diff --git a/changelog.d/2105.misc.rst b/changelog.d/2105.misc.rst |
48 |
+new file mode 100644 |
49 |
+index 000000000..75eaf2cb3 |
50 |
+--- /dev/null |
51 |
++++ b/changelog.d/2105.misc.rst |
52 |
+@@ -0,0 +1 @@ |
53 |
++Filter ``2to3`` deprecation warnings from ``TestDevelop.test_2to3_user_mode``. |
54 |
+diff --git a/setuptools/tests/__init__.py b/setuptools/tests/__init__.py |
55 |
+index 9c77b51f8..6377d7857 100644 |
56 |
+--- a/setuptools/tests/__init__.py |
57 |
++++ b/setuptools/tests/__init__.py |
58 |
+@@ -6,7 +6,7 @@ |
59 |
+ |
60 |
+ |
61 |
+ __all__ = [ |
62 |
+- 'fail_on_ascii', 'py2_only', 'py3_only' |
63 |
++ 'fail_on_ascii', 'py2_only', 'py3_only', 'ack_2to3' |
64 |
+ ] |
65 |
+ |
66 |
+ |
67 |
+@@ -16,3 +16,5 @@ |
68 |
+ |
69 |
+ py2_only = pytest.mark.skipif(not PY2, reason="Test runs on Python 2 only") |
70 |
+ py3_only = pytest.mark.skipif(not PY3, reason="Test runs on Python 3 only") |
71 |
++ |
72 |
++ack_2to3 = pytest.mark.filterwarnings('ignore:2to3 support is deprecated') |
73 |
+diff --git a/setuptools/tests/test_develop.py b/setuptools/tests/test_develop.py |
74 |
+index 792975fd1..bb89a865b 100644 |
75 |
+--- a/setuptools/tests/test_develop.py |
76 |
++++ b/setuptools/tests/test_develop.py |
77 |
+@@ -17,6 +17,7 @@ |
78 |
+ |
79 |
+ from setuptools.command.develop import develop |
80 |
+ from setuptools.dist import Distribution |
81 |
++from setuptools.tests import ack_2to3 |
82 |
+ from . import contexts |
83 |
+ from . import namespaces |
84 |
+ |
85 |
+@@ -65,6 +66,7 @@ class TestDevelop: |
86 |
+ @pytest.mark.skipif( |
87 |
+ in_virtualenv or in_venv, |
88 |
+ reason="Cannot run when invoked in a virtualenv or venv") |
89 |
++ @ack_2to3 |
90 |
+ def test_2to3_user_mode(self, test_env): |
91 |
+ settings = dict( |
92 |
+ name='foo', |
93 |
+diff --git a/setuptools/tests/test_test.py b/setuptools/tests/test_test.py |
94 |
+index 0f77d8ff3..892fd120d 100644 |
95 |
+--- a/setuptools/tests/test_test.py |
96 |
++++ b/setuptools/tests/test_test.py |
97 |
+@@ -10,6 +10,7 @@ |
98 |
+ |
99 |
+ from setuptools.command.test import test |
100 |
+ from setuptools.dist import Distribution |
101 |
++from setuptools.tests import ack_2to3 |
102 |
+ |
103 |
+ from .textwrap import DALS |
104 |
+ |
105 |
+@@ -73,9 +74,6 @@ def quiet_log(): |
106 |
+ log.set_verbosity(0) |
107 |
+ |
108 |
+ |
109 |
+-ack_2to3 = pytest.mark.filterwarnings('ignore:2to3 support is deprecated') |
110 |
+- |
111 |
+- |
112 |
+ @pytest.mark.usefixtures('sample_test', 'quiet_log') |
113 |
+ @ack_2to3 |
114 |
+ def test_test(capfd): |
115 |
|
116 |
diff --git a/dev-python/setuptools/setuptools-46.2.0.ebuild b/dev-python/setuptools/setuptools-46.2.0.ebuild |
117 |
new file mode 100644 |
118 |
index 00000000000..ff041cbacee |
119 |
--- /dev/null |
120 |
+++ b/dev-python/setuptools/setuptools-46.2.0.ebuild |
121 |
@@ -0,0 +1,70 @@ |
122 |
+# Copyright 1999-2020 Gentoo Authors |
123 |
+# Distributed under the terms of the GNU General Public License v2 |
124 |
+ |
125 |
+EAPI=7 |
126 |
+DISTUTILS_USE_SETUPTOOLS=no |
127 |
+PYTHON_COMPAT=( python3_{6,7,8} pypy3 ) |
128 |
+PYTHON_REQ_USE="xml(+)" |
129 |
+ |
130 |
+inherit distutils-r1 |
131 |
+ |
132 |
+DESCRIPTION="Collection of extensions to Distutils" |
133 |
+HOMEPAGE="https://github.com/pypa/setuptools https://pypi.org/project/setuptools/" |
134 |
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.zip" |
135 |
+ |
136 |
+LICENSE="MIT" |
137 |
+SLOT="0" |
138 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
139 |
+IUSE="test" |
140 |
+RESTRICT="!test? ( test )" |
141 |
+ |
142 |
+BDEPEND=" |
143 |
+ app-arch/unzip |
144 |
+ test? ( |
145 |
+ dev-python/mock[${PYTHON_USEDEP}] |
146 |
+ dev-python/pip[${PYTHON_USEDEP}] |
147 |
+ >=dev-python/pytest-3.7.0[${PYTHON_USEDEP}] |
148 |
+ dev-python/pytest-fixture-config[${PYTHON_USEDEP}] |
149 |
+ dev-python/pytest-virtualenv[${PYTHON_USEDEP}] |
150 |
+ dev-python/wheel[${PYTHON_USEDEP}] |
151 |
+ ) |
152 |
+" |
153 |
+PDEPEND=" |
154 |
+ >=dev-python/certifi-2016.9.26[${PYTHON_USEDEP}]" |
155 |
+ |
156 |
+# Force in-source build because build system modifies sources. |
157 |
+DISTUTILS_IN_SOURCE_BUILD=1 |
158 |
+ |
159 |
+DOCS=( {CHANGES,README}.rst docs/{easy_install.txt,pkg_resources.txt,setuptools.txt} ) |
160 |
+ |
161 |
+PATCHES=( |
162 |
+ "${FILESDIR}"/${P}-test-warning.patch |
163 |
+) |
164 |
+ |
165 |
+python_prepare_all() { |
166 |
+ # disable tests requiring a network connection |
167 |
+ rm setuptools/tests/test_packageindex.py || die |
168 |
+ |
169 |
+ # don't run integration tests |
170 |
+ rm setuptools/tests/test_integration.py || die |
171 |
+ |
172 |
+ # xpass-es for me |
173 |
+ sed -i -e '/xfail.*710/d' setuptools/tests/test_archive_util.py || die |
174 |
+ |
175 |
+ # avoid pointless dep on flake8 |
176 |
+ sed -i -e 's:--flake8::' pytest.ini || die |
177 |
+ |
178 |
+ distutils-r1_python_prepare_all |
179 |
+} |
180 |
+ |
181 |
+python_test() { |
182 |
+ distutils_install_for_testing |
183 |
+ # test_easy_install raises a SandboxViolation due to ${HOME}/.pydistutils.cfg |
184 |
+ # It tries to sandbox the test in a tempdir |
185 |
+ HOME="${PWD}" pytest -vv ${PN} || die "Tests failed under ${EPYTHON}" |
186 |
+} |
187 |
+ |
188 |
+python_install() { |
189 |
+ export DISTRIBUTE_DISABLE_VERSIONED_EASY_INSTALL_SCRIPT=1 |
190 |
+ distutils-r1_python_install |
191 |
+} |