Skip to content

Commit 75945f4

Browse files
corona10vstinner
andauthored
no-issue: Update CI to support free-threading (#189)
* no-issue: Update CI to support free-threading * Address code review * Address code review * nit * Update .github/workflows/build.yml Co-authored-by: Victor Stinner <[email protected]> --------- Co-authored-by: Victor Stinner <[email protected]>
1 parent 127e0bd commit 75945f4

File tree

1 file changed

+20
-2
lines changed

1 file changed

+20
-2
lines changed

.github/workflows/build.yml

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,12 @@ jobs:
2222
- run: tox -e ${{ matrix.tox-job }}
2323
build:
2424
runs-on: ${{ matrix.os }}
25+
name: ${{ matrix.os }} - ${{ matrix.python }} ${{ matrix.build }}
2526
strategy:
2627
matrix:
2728
os: [ubuntu-latest, macos-latest, windows-latest]
2829
python: ['3.12']
30+
build: ['']
2931
include:
3032
- os: ubuntu-latest
3133
python: 'pypy3.10'
@@ -41,13 +43,29 @@ jobs:
4143
python: '3.10'
4244
- os: ubuntu-latest
4345
python: '3.11'
46+
- os: ubuntu-latest
47+
python: '3.12'
48+
- os: ubuntu-latest
49+
python: '3.13-dev'
50+
build: 'free-threading'
4451

4552
steps:
46-
- uses: actions/checkout@v3
53+
- uses: actions/checkout@v4
4754
- name: Setup Python
48-
uses: actions/setup-python@v4
55+
uses: actions/setup-python@v5
56+
if: ${{ matrix.build != 'free-threading' }}
57+
with:
58+
python-version: ${{ matrix.python }}
59+
- name: Set up Python ${{ matrix.python }} using deadsnakes
60+
uses: deadsnakes/[email protected]
61+
if: ${{ matrix.build == 'free-threading' }}
4962
with:
5063
python-version: ${{ matrix.python }}
64+
nogil: true
65+
- name: Display Python version
66+
run: |
67+
python -VV
68+
python -c 'import sysconfig; print("Free threading?", "Yes" if sysconfig.get_config_var("Py_GIL_DISABLED") else "No")'
5169
- name: Install Tox and any other packages
5270
run: pip install tox
5371
- name: Run Tox

0 commit comments

Comments
 (0)