Skip to content

Commit 8c562f4

Browse files
committed
CI: use --break-system-packages when using pip globally
seems like recent versions of pip on some OSes is preventing the user from installing things globally we should override it, since we know what are we doing (most of the time). anyhow that code is run only in CI, and never locally Ref: https://veronneau.org/python-311-pip-and-breaking-system-packages.html
1 parent 82b4863 commit 8c562f4

File tree

1 file changed

+11
-6
lines changed

1 file changed

+11
-6
lines changed

.github/workflows/build-push.yml

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,16 @@ jobs:
4646
platform: PyPy
4747

4848
steps:
49-
- uses: actions/checkout@v3
49+
- uses: actions/checkout@v4
5050

51-
- uses: actions/setup-python@v4
51+
- uses: actions/setup-python@v5
5252
name: Install Python
5353

54+
- name: Enable pip installing globally
55+
if: runner.os == 'MacOs' || runner.os == 'Windows'
56+
run: |
57+
echo "PIP_BREAK_SYSTEM_PACKAGES=1" >> $GITHUB_ENV
58+
5459
- name: Install cibuildwheel
5560
run: |
5661
python3 -m pip install cibuildwheel==2.16.2
@@ -124,17 +129,17 @@ jobs:
124129
if: "(!contains(github.event.pull_request.labels.*.name, 'disable-test-build'))|| github.event_name == 'push' && endsWith(github.event.ref, 'scylla')"
125130
runs-on: ubuntu-latest
126131
steps:
127-
- uses: actions/checkout@v3
132+
- uses: actions/checkout@v4
128133

129-
- uses: actions/setup-python@v4
134+
- uses: actions/setup-python@v5
130135
name: Install Python
131136

132137
- name: Build sdist
133138
run: |
134139
pip install build
135140
python -m build --sdist
136141
137-
- uses: actions/upload-artifact@v2
142+
- uses: actions/upload-artifact@v4
138143
with:
139144
path: dist/*.tar.gz
140145

@@ -146,7 +151,7 @@ jobs:
146151
# alternatively, to publish when a GitHub Release is created, use the following rule:
147152
# if: github.event_name == 'release' && github.event.action == 'published'
148153
steps:
149-
- uses: actions/download-artifact@v2
154+
- uses: actions/download-artifact@v4
150155
with:
151156
name: artifact
152157
path: dist

0 commit comments

Comments
 (0)