File: bundled-wheel-and-setuptools

package info (click to toggle)
python-cffi 2.0.0~b1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 2,796 kB
  • sloc: python: 28,456; ansic: 15,272; asm: 116; makefile: 97; sh: 14
file content (38 lines) | stat: -rw-r--r-- 1,408 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
From: Stefano Rivera <stefanor@debian.org>
Date: Sat, 4 Nov 2023 18:59:01 +0200
Subject: Use virtualenvs' bundled wheel and setuptools

We can't install it from the Internet in our builds, without Internet
access.

Bug-Debian: https://bugs.debian.org/1055337
---
 testing/cffi0/test_zintegration.py | 14 +-------------
 1 file changed, 1 insertion(+), 13 deletions(-)

diff --git a/testing/cffi0/test_zintegration.py b/testing/cffi0/test_zintegration.py
index 8d71d81..ec990e8 100644
--- a/testing/cffi0/test_zintegration.py
+++ b/testing/cffi0/test_zintegration.py
@@ -22,20 +22,8 @@ def create_venv(name):
             #'--never-download', <= could be added, but causes failures
             # in random cases on random machines
                                '-p', os.path.abspath(sys.executable),
+                               '--wheel=bundle', '--setuptools=bundle',
                                str(tmpdir)])
-
-        # Newer venv/virtualenv no longer include setuptools and wheel by default, which
-        # breaks a number of these tests; ensure they're always present
-        subprocess.check_call([
-            os.path.join(tmpdir, 'bin/python'),
-            '-m',
-            'pip',
-            'install',
-            'setuptools',
-            'wheel',
-            '--upgrade'
-        ])
-
     except OSError as e:
         pytest.skip("Cannot execute virtualenv: %s" % (e,))