Skip to content

Commit 8aaabf0

Browse files
committed
Upgrade pip via python -m pip in CI
On Windows the `pip.exe` shim refuses to replace itself: ERROR: To modify pip, please run the following command: ...\python.exe -m pip install -U pip Because a multi-line `run:` under pwsh only propagates the last command's exit code, that failure went unnoticed, leaving the PyPy/Windows job on the pip 24.0 that ensurepip ships. That pip does not invalidate corrupt entries in its HTTP cache, so once the persisted `Windows-X64-pip-pypy-3.11` cache contained a bad record, every run restoring it failed with `OSError: Connection broken: IncompleteRead(...)` until GitHub happened to evict the entry.
1 parent b0ddabd commit 8aaabf0

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

.github/workflows/tests.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -163,12 +163,12 @@ jobs:
163163
- name: Install Build Dependencies (3.15)
164164
if: startsWith(matrix.python-version, '3.15')
165165
run: |
166-
pip install -U pip
166+
python -m pip install -U pip
167167
pip install -U "setuptools >= 78.1.1,< 82" wheel twine cffi pycparser
168168
- name: Install Build Dependencies
169169
if: ${{ !startsWith(matrix.python-version, '3.15') }}
170170
run: |
171-
pip install -U pip
171+
python -m pip install -U pip
172172
pip install -U "setuptools >= 78.1.1,< 82" wheel twine
173173
174174
- name: Build zope.interface (macOS x86_64)
@@ -225,7 +225,7 @@ jobs:
225225
if: ${{ !startsWith(matrix.python-version, '3.15') }}
226226
run: |
227227
# Install to collect dependencies into the (pip) cache.
228-
pip install -U pip "setuptools >= 78.1.1,< 82"
228+
python -m pip install -U pip "setuptools >= 78.1.1,< 82"
229229
pip install .[test]
230230
231231
- name: Check zope.interface build
@@ -602,7 +602,7 @@ jobs:
602602

603603

604604
- name: Update pip
605-
run: pip install -U pip
605+
run: python -m pip install -U pip
606606

607607
- name: Build zope.interface
608608
if: matrix.image != 'manylinux2014_i686'

0 commit comments

Comments
 (0)