Skip to content

Commit a9be84a

Browse files
authored
Merge branch 'pypa:main' into perf-requirement-cache-size
2 parents 19e774d + d97fd0b commit a9be84a

File tree

438 files changed

+19334
-15371
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

438 files changed

+19334
-15371
lines changed

.git-blame-ignore-revs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,3 +34,4 @@ c7ee560e00b85f7486b452c14ff49e4737996eda # Blacken tools/
3434
94999255d5ede440c37137d210666fdf64302e75 # Reformat the codebase, with black
3535
585037a80a1177f1fa92e159a7079855782e543e # Cleanup implicit string concatenation
3636
8a6f6ac19b80a6dc35900a47016c851d9fcd2ee2 # Blacken src/pip/_internal/resolution directory
37+
acfcae8941bb12ecfc372a05c875a7b414992604 # Reformat with Black's 2025 code style

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,6 @@
33

44
blank_issues_enabled: false
55
contact_links:
6-
- name: "💬 IRC: #pypa"
7-
url: https://kiwiirc.com/nextclient/#ircs://irc.libera.chat:+6697/pypa
8-
about: Chat with devs
96
- name: "(maintainers only) Blank issue"
107
url: https://github.com/pypa/pip/issues/new
118
about: For maintainers only.

.github/dependabot.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,12 @@ updates:
33
- package-ecosystem: "github-actions"
44
directory: "/"
55
schedule:
6-
interval: "monthly"
6+
interval: "weekly"
7+
groups:
8+
github-actions:
9+
patterns:
10+
- "*"
11+
- package-ecosystem: "pip"
12+
directory: "/"
13+
schedule:
14+
interval: "weekly"

.github/triage-new-issues.yml

Lines changed: 0 additions & 7 deletions
This file was deleted.

.github/workflows/ci.yml

Lines changed: 49 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ on:
1010
pull_request:
1111
schedule:
1212
- cron: 0 0 * * MON # Run every Monday at 00:00 UTC
13+
workflow_dispatch:
14+
# allow manual runs on branches without a PR
1315

1416
env:
1517
# The "FORCE_COLOR" variable, when set to 1,
@@ -23,7 +25,7 @@ concurrency:
2325
jobs:
2426
docs:
2527
name: docs
26-
runs-on: ubuntu-latest
28+
runs-on: ubuntu-22.04
2729

2830
steps:
2931
- uses: actions/checkout@v4
@@ -34,13 +36,13 @@ jobs:
3436
- run: nox -s docs
3537

3638
determine-changes:
37-
runs-on: ubuntu-latest
39+
runs-on: ubuntu-22.04
3840
outputs:
3941
tests: ${{ steps.filter.outputs.tests }}
4042
vendoring: ${{ steps.filter.outputs.vendoring }}
4143
steps:
4244
# For pull requests it's not necessary to checkout the code
43-
- uses: dorny/paths-filter@v2
45+
- uses: dorny/paths-filter@v3
4446
id: filter
4547
with:
4648
filters: |
@@ -55,11 +57,14 @@ jobs:
5557
- "src/**"
5658
- "tests/**"
5759
- "noxfile.py"
60+
# The test suite should also run when cutting a release
61+
# (which is the only time this file is modified).
62+
- "NEWS.rst"
5863
if: github.event_name == 'pull_request'
5964

6065
packaging:
6166
name: packaging
62-
runs-on: ubuntu-latest
67+
runs-on: ubuntu-22.04
6368

6469
steps:
6570
- uses: actions/checkout@v4
@@ -78,7 +83,7 @@ jobs:
7883

7984
vendoring:
8085
name: vendoring
81-
runs-on: ubuntu-latest
86+
runs-on: ubuntu-22.04
8287

8388
needs: [determine-changes]
8489
if: >-
@@ -107,9 +112,8 @@ jobs:
107112
strategy:
108113
fail-fast: true
109114
matrix:
110-
os: [ubuntu-latest, macos-12]
115+
os: [ubuntu-22.04, macos-13, macos-latest]
111116
python:
112-
- "3.8"
113117
- "3.9"
114118
- "3.10"
115119
- "3.11"
@@ -124,32 +128,37 @@ jobs:
124128
allow-prereleases: true
125129

126130
- name: Install Ubuntu dependencies
127-
if: matrix.os == 'ubuntu-latest'
131+
if: matrix.os == 'ubuntu-22.04'
128132
run: |
129133
sudo apt-get update
130134
sudo apt-get install bzr
131135
132136
- name: Install MacOS dependencies
133-
if: matrix.os == 'macos-12'
134-
run: brew install breezy
137+
if: runner.os == 'macOS'
138+
run: |
139+
DEPS=breezy
140+
if ! which svn; then
141+
DEPS="${DEPS} subversion"
142+
fi
143+
brew install ${DEPS}
135144
136145
- run: pip install nox
137146

138147
# Main check
139148
- name: Run unit tests
140149
run: >-
141150
nox -s test-${{ matrix.python.key || matrix.python }} --
142-
-m unit
151+
tests/unit
143152
--verbose --numprocesses auto --showlocals
144153
- name: Run integration tests
145154
run: >-
146-
nox -s test-${{ matrix.python.key || matrix.python }} --
147-
-m integration
155+
nox -s test-${{ matrix.python.key || matrix.python }} --no-install --
156+
tests/functional
148157
--verbose --numprocesses auto --showlocals
149158
--durations=5
150159
151160
tests-windows:
152-
name: tests / ${{ matrix.python }} / ${{ matrix.os }} / ${{ matrix.group }}
161+
name: tests / ${{ matrix.python }} / ${{ matrix.os }} / ${{ matrix.group.number }}
153162
runs-on: ${{ matrix.os }}-latest
154163

155164
needs: [packaging, determine-changes]
@@ -162,62 +171,53 @@ jobs:
162171
matrix:
163172
os: [Windows]
164173
python:
165-
- "3.8"
174+
- "3.9"
166175
# Commented out, since Windows tests are expensively slow,
167176
# only test the oldest and newest Python supported by pip
168-
# - "3.9"
169177
# - "3.10"
170178
# - "3.11"
171-
- "3.12" # Comment out when 3.13 is final
179+
# - "3.12"
172180
- "3.13"
173-
group: [1, 2]
181+
group:
182+
- { number: 1, pytest-filter: "not test_install" }
183+
- { number: 2, pytest-filter: "test_install" }
174184

175185
steps:
186+
# The D: drive is significantly faster than the system C: drive.
187+
# https://github.com/actions/runner-images/issues/8755
188+
- name: Set TEMP to D:/Temp
189+
run: |
190+
mkdir "D:\\Temp"
191+
echo "TEMP=D:\\Temp" >> $env:GITHUB_ENV
192+
176193
- uses: actions/checkout@v4
177194
- uses: actions/setup-python@v5
178195
with:
179196
python-version: ${{ matrix.python }}
180197
allow-prereleases: true
181198

182-
# We use C:\Temp (which is already available on the worker)
183-
# as a temporary directory for all of the tests because the
184-
# default value (under the user dir) is more deeply nested
185-
# and causes tests to fail with "path too long" errors.
186199
- run: pip install nox
187-
env:
188-
TEMP: "C:\\Temp"
189200

190201
# Main check
191-
- name: Run unit tests
192-
if: matrix.group == 1
193-
run: >-
194-
nox -s test-${{ matrix.python }} --
195-
-m unit
196-
--verbose --numprocesses auto --showlocals
197-
env:
198-
TEMP: "C:\\Temp"
199-
200-
- name: Run integration tests (group 1)
201-
if: matrix.group == 1
202+
- name: Run unit tests (group 1)
203+
if: matrix.group.number == 1
202204
run: >-
203205
nox -s test-${{ matrix.python }} --
204-
-m integration -k "not test_install"
206+
tests/unit
205207
--verbose --numprocesses auto --showlocals
206-
env:
207-
TEMP: "C:\\Temp"
208208
209-
- name: Run integration tests (group 2)
210-
if: matrix.group == 2
209+
- name: Run integration tests (group ${{ matrix.group.number }})
211210
run: >-
212-
nox -s test-${{ matrix.python }} --
213-
-m integration -k "test_install"
211+
nox -s test-${{ matrix.python }} --no-install --
212+
tests/functional -k "${{ matrix.group.pytest-filter }}"
214213
--verbose --numprocesses auto --showlocals
215-
env:
216-
TEMP: "C:\\Temp"
217214
218215
tests-zipapp:
219216
name: tests / zipapp
220-
runs-on: ubuntu-latest
217+
# The macos-latest (M1) runners are the fastest available on GHA, even
218+
# beating out the ubuntu-latest runners. The zipapp tests are slow by
219+
# nature, and we don't care where they run, so we pick the fastest one.
220+
runs-on: macos-latest
221221

222222
needs: [packaging, determine-changes]
223223
if: >-
@@ -230,18 +230,16 @@ jobs:
230230
with:
231231
python-version: "3.10"
232232

233-
- name: Install Ubuntu dependencies
234-
run: |
235-
sudo apt-get update
236-
sudo apt-get install bzr
233+
- name: Install MacOS dependencies
234+
run: brew install breezy subversion
237235

238236
- run: pip install nox
239237

240238
# Main check
241239
- name: Run integration tests
242240
run: >-
243241
nox -s test-3.10 --
244-
-m integration
242+
tests/functional
245243
--verbose --numprocesses auto --showlocals
246244
--durations=5
247245
--use-zipapp
@@ -258,7 +256,7 @@ jobs:
258256
- tests-zipapp
259257
- vendoring
260258

261-
runs-on: ubuntu-latest
259+
runs-on: ubuntu-22.04
262260

263261
steps:
264262
- name: Decide whether the needed jobs succeeded or failed

.github/workflows/lock-threads.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
if: github.repository_owner == 'pypa'
1818
runs-on: ubuntu-latest
1919
steps:
20-
- uses: dessant/lock-threads@v4
20+
- uses: dessant/lock-threads@v5
2121
with:
2222
issue-inactive-days: '30'
2323
pr-inactive-days: '15'

.github/workflows/news-file.yml

Lines changed: 0 additions & 25 deletions
This file was deleted.

.github/workflows/release.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: Publish Python 🐍 distribution 📦 to PyPI
2+
3+
on:
4+
push:
5+
tags:
6+
- "*"
7+
8+
jobs:
9+
build:
10+
name: Build distribution 📦
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
15+
with:
16+
persist-credentials: false
17+
- name: Build a binary wheel and a source tarball
18+
run: ./build-project.py
19+
- name: Store the distribution packages
20+
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4
21+
with:
22+
name: python-package-distributions
23+
path: dist/
24+
25+
publish-to-pypi:
26+
name: >-
27+
Publish Python 🐍 distribution 📦 to PyPI
28+
needs:
29+
- build
30+
runs-on: ubuntu-latest
31+
environment:
32+
name: pypi
33+
url: https://pypi.org/project/pip/${{ github.ref_name }}
34+
permissions:
35+
id-token: write # IMPORTANT: mandatory for trusted publishing
36+
37+
steps:
38+
- name: Download all the dists
39+
uses: actions/download-artifact@cc203385981b70ca67e1cc392babf9cc229d5806 # v4
40+
with:
41+
name: python-package-distributions
42+
path: dist/
43+
- name: Publish distribution 📦 to PyPI
44+
uses: pypa/gh-action-pypi-publish@76f52bc884231f62b9a034ebfe128415bbaabdfc # release/v1

.github/workflows/update-rtd-redirects.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ name: Update documentation redirects
33
on:
44
push:
55
branches: [main]
6+
paths:
7+
- ".readthedocs-custom-redirects.yml"
8+
- ".readthedocs.yml"
69
schedule:
710
- cron: 0 0 * * MON # Run every Monday at 00:00 UTC
811

@@ -22,7 +25,6 @@ jobs:
2225
- uses: actions/setup-python@v5
2326
with:
2427
python-version: "3.11"
25-
- run: pip install httpx pyyaml rich
26-
- run: python tools/update-rtd-redirects.py
28+
- run: pipx run tools/update-rtd-redirects.py
2729
env:
2830
RTD_API_TOKEN: ${{ secrets.RTD_API_TOKEN }}

0 commit comments

Comments
 (0)