8000 [3.12] Merge Ubuntu test matrices in CI (GH-121813) · python/cpython@e1254a8 · GitHub
[go: up one dir, main page]

Skip to content
8000

Commit e1254a8

Browse files
committed
[3.12] Merge Ubuntu test matrices in CI (GH-121813)
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>. (cherry picked from commit a3f7db9) Co-authored-by: Sviatoslav Sydorenko (Святослав Сидоренко) <wk.cvs.github@sydorenko.org.ua>
1 parent 6586b17 commit e1254a8

File tree

2 files changed

+20
-10
lines changed

2 files changed

+20
-10
lines changed

.github/workflows/build.yml

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -253,17 +253,20 @@ jobs:
253253
os-matrix: '["ghcr.io/cirruslabs/macos-runner:sonoma", "macos-14", "macos-13"]'
254254

255255
build_ubuntu:
256-
name: 'Ubuntu'
256+
name: >-
257+
Ubuntu
258+
${{ fromJSON(matrix.free-threading) && '(free-threading)' || '' }}
257259
needs: check_source
258260
if: needs.check_source.outputs.run_tests == 'true'
261+
strategy:
262+
matrix:
263+
free-threading:
264+
- false
265+
- true
259266
uses: ./.github/workflows/reusable-ubuntu.yml
260267
with:
261268
config_hash: ${{ needs.check_source.outputs.config_hash }}
262-
options: |
263-
../cpython-ro-srcdir/configure \
264-
--config-cache \
265-
--with-pydebug \
266-
--with-openssl=$OPENSSL_DIR
269+
free-threading: ${{ matrix.free-threading }}
267270

268271
build_ubuntu_ssltests:
269272
name: 'Ubuntu SSL tests with OpenSSL'

.github/workflows/reusable-ubuntu.yml

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,11 @@ on:
44
config_hash:
55
required: true
66
type: string
7-
options:
8-
required: true
9-
type: string
7+
free-threading:
8+
description: Whether to use free-threaded mode
9+
required: false
10+
type: boolean
11+
default: false
1012

1113
jobs:
1214
build_ubuntu_reusable:
@@ -61,7 +63,12 @@ jobs:
6163
key: ${{ github.job }}-${{ runner.os }}-${{ env.IMAGE_VERSION }}-${{ inputs.config_hash }}
6264
- name: Configure CPython out-of-tree
6365
working-directory: ${{ env.CPYTHON_BUILDDIR }}
64-
run: ${{ inputs.options }}
66+
run: >-
67+
../cpython-ro-srcdir/configure
68+
--config-cache
69+
--with-pydebug
70+
--with-openssl=$OPENSSL_DIR
71+
${{ fromJSON(inputs.free-threading) && '--disable-gil' || '' }}
6572
- name: Build CPython out-of-tree
6673
working-directory: ${{ env.CPYTHON_BUILDDIR }}
6774
run: make -j4

0 commit comments

Comments
 (0)
0