Skip to content

Commit f3c03d0

Browse files
committed
ci: install Python the same way everywhere
For wheel builds, we shouldn't create a virtualenv, as it conflicts with the check phase
1 parent 6e07439 commit f3c03d0

File tree

2 files changed

+10
-7
lines changed

2 files changed

+10
-7
lines changed

.github/actions/setup-dependencies/action.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,3 +39,7 @@ runs:
3939
- name: Install the project
4040
run: uv sync
4141
shell: bash
42+
43+
- name: Setup pip # some tools need it, and uv virtualenvs doesn't contain it
44+
run: uv pip install pip
45+
shell: bash

.github/workflows/CI.yml

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,6 @@ jobs:
3434
- name: Checkout source code
3535
uses: actions/checkout@v4
3636

37-
- name: Setup Python
38-
uses: actions/setup-python@v5
39-
4037
- name: Setup 3rd party dependencies
4138
uses: ./.github/actions/setup-dependencies
4239
with:
@@ -129,9 +126,10 @@ jobs:
129126
- name: Checkout source code
130127
uses: actions/checkout@v4
131128

132-
- uses: actions/setup-python@v5
129+
- name: Setup 3rd party dependencies
130+
uses: ./.github/actions/setup-dependencies
133131
with:
134-
python-version: 3.x
132+
install-test-deps: "false"
135133

136134
- name: Build wheels
137135
uses: PyO3/maturin-action@v1
@@ -221,9 +219,10 @@ jobs:
221219
- name: Checkout source code
222220
uses: actions/checkout@v4
223221

224-
- uses: actions/setup-python@v5
222+
- name: Setup 3rd party dependencies
223+
uses: ./.github/actions/setup-dependencies
225224
with:
226-
python-version: 3.x
225+
install-test-deps: "false"
227226

228227
- name: Build wheels
229228
uses: PyO3/maturin-action@v1

0 commit comments

Comments
 (0)