Skip to content

Commit f73a2f3

Browse files
authored
Fix broken Windows zipapp and drop 3.7 support (#2783)
1 parent 228b615 commit f73a2f3

File tree

17 files changed

+96
-93
lines changed

17 files changed

+96
-93
lines changed

.github/workflows/check.yaml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,6 @@ jobs:
3939
- { os: macos-latest, py: "[email protected]" }
4040
- { os: macos-latest, py: "[email protected]" }
4141
- { os: macos-latest, py: "[email protected]" }
42-
- { os: macos-latest, py: "[email protected]" }
43-
- { os: ubuntu-latest, py: "3.7" }
44-
- { os: macos-13, py: "3.7" }
4542
exclude:
4643
- { os: windows-latest, py: "pypy-3.10" }
4744
- { os: windows-latest, py: "pypy-3.9" }

docs/changelog/2758.feature.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Drop 3.7 support as the CI environments no longer allow it running - by :user:`gaborbernat`.

docs/changelog/2783.bugfix.rst

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
Upgrade embedded wheels:
2+
3+
* setuptools to ``75.2.0`` from ``75.1.0``
4+
* Removed pip of ``24.0``
5+
* Removed setuptools of ``68.0.0``
6+
* Removed wheel of ``0.42.0``
7+
8+
- by :user:`gaborbernat`.

docs/changelog/2784.bugfix.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fix zipapp is broken on Windows post distlib ``0.3.9`` - by :user:`gaborbernat`.

docs/installation.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@ request on our issue tracker.
9797

9898
Note:
9999

100+
- as of ``20.27.0`` -- ``2024-10-17`` -- we no longer support running under Python ``<=3.7``,
100101
- as of ``20.18.0`` -- ``2023-02-06`` -- we no longer support running under Python ``<=3.6``,
101102
- as of ``20.22.0`` -- ``2023-04-19`` -- we no longer support creating environments for Python ``<=3.6``.
102103

@@ -120,4 +121,4 @@ In case of macOS we support:
120121
Windows
121122
~~~~~~~
122123
- Installations from `python.org <https://www.python.org/downloads/>`_
123-
- Windows Store Python - note only `version 3.7+ <https://www.microsoft.com/en-us/p/python-38/9mssztt1n39l>`_
124+
- Windows Store Python - note only `version 3.8+ <https://www.microsoft.com/en-us/p/python-38/9mssztt1n39l>`_

pyproject.toml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ license = "MIT"
1818
maintainers = [
1919
{ name = "Bernat Gabor", email = "[email protected]" },
2020
]
21-
requires-python = ">=3.7"
21+
requires-python = ">=3.8"
2222
classifiers = [
2323
"Development Status :: 5 - Production/Stable",
2424
"Intended Audience :: Developers",
@@ -27,7 +27,6 @@ classifiers = [
2727
"Operating System :: Microsoft :: Windows",
2828
"Operating System :: POSIX",
2929
"Programming Language :: Python :: 3 :: Only",
30-
"Programming Language :: Python :: 3.7",
3130
"Programming Language :: Python :: 3.8",
3231
"Programming Language :: Python :: 3.9",
3332
"Programming Language :: Python :: 3.10",
@@ -106,7 +105,6 @@ build.targets.sdist.include = [
106105
version.source = "vcs"
107106

108107
[tool.ruff]
109-
target-version = "py37"
110108
line-length = 120
111109
format.preview = true
112110
format.docstring-code-line-length = 100
@@ -128,6 +126,7 @@ lint.ignore = [
128126
"PLR0914", # Too many local variables
129127
"PLR0917", # Too many positional arguments
130128
"PLR6301", # Method could be a function, class method, or static method
129+
"PLW1510", # no need for check for subprocess
131130
"PTH", # no pathlib, <=39 has problems on Windows with absolute/resolve, can revisit once we no longer need 39
132131
"S104", # Possible binding to all interfaces
133132
"S404", # Using subprocess is alright

src/virtualenv/run/plugin/base.py

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,9 @@
22

33
import sys
44
from collections import OrderedDict
5+
from importlib.metadata import entry_points
56

6-
if sys.version_info >= (3, 8):
7-
from importlib.metadata import entry_points
8-
9-
importlib_metadata_version = ()
10-
else:
11-
from importlib_metadata import entry_points, version
12-
13-
importlib_metadata_version = tuple(int(i) for i in version("importlib_metadata").split(".")[:2])
7+
importlib_metadata_version = ()
148

159

1610
class PluginLoader:

src/virtualenv/seed/wheels/embed/__init__.py

Lines changed: 8 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -6,48 +6,43 @@
66

77
BUNDLE_FOLDER = Path(__file__).absolute().parent
88
BUNDLE_SUPPORT = {
9-
"3.7": {
10-
"pip": "pip-24.0-py3-none-any.whl",
11-
"setuptools": "setuptools-68.0.0-py3-none-any.whl",
12-
"wheel": "wheel-0.42.0-py3-none-any.whl",
13-
},
149
"3.8": {
1510
"pip": "pip-24.2-py3-none-any.whl",
16-
"setuptools": "setuptools-75.1.0-py3-none-any.whl",
11+
"setuptools": "setuptools-75.2.0-py3-none-any.whl",
1712
"wheel": "wheel-0.44.0-py3-none-any.whl",
1813
},
1914
"3.9": {
2015
"pip": "pip-24.2-py3-none-any.whl",
21-
"setuptools": "setuptools-75.1.0-py3-none-any.whl",
16+
"setuptools": "setuptools-75.2.0-py3-none-any.whl",
2217
"wheel": "wheel-0.44.0-py3-none-any.whl",
2318
},
2419
"3.10": {
2520
"pip": "pip-24.2-py3-none-any.whl",
26-
"setuptools": "setuptools-75.1.0-py3-none-any.whl",
21+
"setuptools": "setuptools-75.2.0-py3-none-any.whl",
2722
"wheel": "wheel-0.44.0-py3-none-any.whl",
2823
},
2924
"3.11": {
3025
"pip": "pip-24.2-py3-none-any.whl",
31-
"setuptools": "setuptools-75.1.0-py3-none-any.whl",
26+
"setuptools": "setuptools-75.2.0-py3-none-any.whl",
3227
"wheel": "wheel-0.44.0-py3-none-any.whl",
3328
},
3429
"3.12": {
3530
"pip": "pip-24.2-py3-none-any.whl",
36-
"setuptools": "setuptools-75.1.0-py3-none-any.whl",
31+
"setuptools": "setuptools-75.2.0-py3-none-any.whl",
3732
"wheel": "wheel-0.44.0-py3-none-any.whl",
3833
},
3934
"3.13": {
4035
"pip": "pip-24.2-py3-none-any.whl",
41-
"setuptools": "setuptools-75.1.0-py3-none-any.whl",
36+
"setuptools": "setuptools-75.2.0-py3-none-any.whl",
4237
"wheel": "wheel-0.44.0-py3-none-any.whl",
4338
},
4439
"3.14": {
4540
"pip": "pip-24.2-py3-none-any.whl",
46-
"setuptools": "setuptools-75.1.0-py3-none-any.whl",
41+
"setuptools": "setuptools-75.2.0-py3-none-any.whl",
4742
"wheel": "wheel-0.44.0-py3-none-any.whl",
4843
},
4944
}
50-
MAX = "3.7"
45+
MAX = "3.8"
5146

5247

5348
def get_embed_wheel(distribution, for_py_version):
-2.01 MB
Binary file not shown.
Binary file not shown.

0 commit comments

Comments
 (0)