Skip to content

Commit 2e0da9b

Browse files
committed
Add 3.13t to CI
1 parent 39d9504 commit 2e0da9b

File tree

4 files changed

+64
-18
lines changed

4 files changed

+64
-18
lines changed

.github/workflows/_build_linux.yml

+22-4
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,10 @@ jobs:
3737
set -ex
3838
uv python list --only-installed
3939
40-
py_ver="$(echo '${{ inputs.python-version }}' | sed 's|[^0-9]*||g')"
41-
python_exe="/opt/python/cp${py_ver}-cp${py_ver}/bin/python"
40+
# note: 3.13t is in cp313-cp313t directory, others are in cp313-cp313 directory
41+
v=${{ inputs.python-version }}
42+
dir="cp${v//[.t]/}-cp${v//[.]/}"
43+
python_exe="/opt/python/${dir}/bin/python"
4244
uv venv --python "${python_exe}"
4345
uv build --all-packages --wheel
4446
@@ -54,9 +56,14 @@ jobs:
5456
overwrite: true
5557

5658
- name: Check package
59+
# CFFI is not available yet for 3.13t, which prevents the installation of twine
60+
# https://github.com/python-cffi/cffi/releases/tag/v1.17.0
61+
if: ${{ inputs.python-version != '3.13t' }}
5762
run: |
58-
py_ver="$(echo '${{ inputs.python-version }}' | sed 's|[^0-9]*||g')"
59-
python_exe="/opt/python/cp${py_ver}-cp${py_ver}/bin/python"
63+
# note: 3.13t is in cp313-cp313t directory, others are in cp313-cp313 directory
64+
v=${{ inputs.python-version }}
65+
dir="cp${v//[.t]/}-cp${v//[.]/}"
66+
python_exe="/opt/python/${dir}/bin/python"
6067
"${python_exe}" -m pip install -r ./packaging/requirements.txt
6168
"${python_exe}" -m twine check --strict ~/package/*.whl
6269
@@ -83,12 +90,23 @@ jobs:
8390
path: ~/package
8491

8592
- uses: conda-incubator/setup-miniconda@v3
93+
if: ${{ inputs.python-version != '3.13t' }}
8694
with:
8795
python-version: ${{ inputs.python-version }}
8896
conda-remove-defaults: "true"
8997

98+
- uses: conda-incubator/setup-miniconda@v3
99+
if: ${{ inputs.python-version == '3.13t' }}
100+
with:
101+
python-version: '3.13'
102+
conda-remove-defaults: "true"
103+
90104
- name: Unit test
91105
run: |
106+
if [[ "${{ inputs.python-version }}" == '3.13t' ]]; do
107+
conda install -q -c conda-forge python-freethreading
108+
fi
109+
92110
pip install $(find "${HOME}/package" -name '*.whl' -depth -maxdepth 1)
93111
# Note: Somehow FFmepg 5.1 does not install libiconv so specifying it here
94112
conda install -q -c conda-forge "ffmpeg==${{ matrix.ffmpeg-version }}" libiconv

.github/workflows/_build_linux_cuda.yml

+23-6
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,10 @@ jobs:
6161
source $HOME/.local/bin/env
6262
uv python list --only-installed
6363
64-
py_ver="$(echo '${{ inputs.python-version }}' | sed 's|[^0-9]*||g')"
65-
python_exe="/opt/python/cp${py_ver}-cp${py_ver}/bin/python"
64+
# note: 3.13t is in cp313-cp313t directory, others are in cp313-cp313 directory
65+
v=${{ inputs.python-version }}
66+
dir="cp${v//[.t]/}-cp${v//[.]/}"
67+
python_exe="/opt/python/${dir}/bin/python"
6668
uv venv --python "${python_exe}"
6769
uv build --all-packages --wheel
6870
@@ -78,10 +80,14 @@ jobs:
7880
overwrite: true
7981

8082
- name: Check package
83+
# CFFI is not available yet for 3.13t, which prevents the installation of twine
84+
# https://github.com/python-cffi/cffi/releases/tag/v1.17.0
85+
if: ${{ inputs.python-version != '3.13t' }}
8186
run: |
82-
py_ver="$(echo '${{ inputs.python-version }}' | sed 's|[^0-9]*||g')"
83-
python_exe="/opt/python/cp${py_ver}-cp${py_ver}/bin/python"
84-
87+
# note: 3.13t is in cp313-cp313t directory, others are in cp313-cp313 directory
88+
v=${{ inputs.python-version }}
89+
dir="cp${v//[.t]/}-cp${v//[.]/}"
90+
python_exe="/opt/python/${dir}/bin/python"
8591
"${python_exe}" -m pip install -r ./packaging/requirements.txt
8692
"${python_exe}" -m twine check --strict ~/package/*.whl
8793
@@ -108,12 +114,23 @@ jobs:
108114
path: ~/package
109115

110116
- uses: conda-incubator/setup-miniconda@v3
117+
if: ${{ inputs.python-version != '3.13t' }}
118+
with:
119+
python-version: ${{ inputs.python-version }}
120+
conda-remove-defaults: "true"
121+
122+
- uses: conda-incubator/setup-miniconda@v3
123+
if: ${{ inputs.python-version == '3.13t' }}
111124
with:
112-
python-version: "${{ inputs.python-version }}"
125+
python-version: '3.13'
113126
conda-remove-defaults: "true"
114127

115128
- name: Unit test
116129
run: |
130+
if [[ "${{ inputs.python-version }}" == '3.13t' ]]; do
131+
conda install -q -c conda-forge python-freethreading
132+
fi
133+
117134
pip install $(find "${HOME}/package" -name '*.whl' -depth -maxdepth 1)
118135
conda install -q -c conda-forge "ffmpeg==${{ matrix.ffmpeg-version }}"
119136
# For some reason, the FFmpeg dynamic libraries are not found.

.github/workflows/_build_macos.yml

+11
Original file line numberDiff line numberDiff line change
@@ -72,12 +72,23 @@ jobs:
7272
path: ~/package
7373

7474
- uses: conda-incubator/setup-miniconda@v3
75+
if: ${{ inputs.python-version != '3.13t' }}
7576
with:
7677
python-version: ${{ inputs.python-version }}
7778
conda-remove-defaults: "true"
7879

80+
- uses: conda-incubator/setup-miniconda@v3
81+
if: ${{ inputs.python-version == '3.13t' }}
82+
with:
83+
python-version: '3.13'
84+
conda-remove-defaults: "true"
85+
7986
- name: Unit test
8087
run: |
88+
if [[ "${{ inputs.python-version }}" == '3.13t' ]]; do
89+
conda install -q -c conda-forge python-freethreading
90+
fi
91+
8192
pip install $(find "${HOME}/package" -name '*.whl' -depth -maxdepth 1)
8293
conda install -q -c conda-forge "ffmpeg==${{ matrix.ffmpeg-version }}"
8394
conda install -q -c pytorch numpy pytest pytorch numba

.github/workflows/packaging.yml

+8-8
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@ jobs:
2626
strategy:
2727
fail-fast: false
2828
matrix:
29-
python-version: ["3.10", "3.11", "3.12", "3.13"]
29+
python-version: ["3.10", "3.11", "3.12", "3.13", "3.13t"]
3030
uses: ./.github/workflows/_build_macos.yml
3131
with:
3232
python-version: "${{ matrix.python-version }}"
33-
run-test: "${{ matrix.python-version == '3.10'}}"
33+
run-test: "${{ matrix.python-version == '3.10' || matrix.python-version == '3.13t' }}"
3434

3535
#############################################################################
3636
# Linux (CPU)
@@ -40,26 +40,26 @@ jobs:
4040
strategy:
4141
fail-fast: false
4242
matrix:
43-
python-version: ["3.10", "3.11", "3.12", "3.13"]
43+
python-version: ["3.10", "3.11", "3.12", "3.13", "3.13t"]
4444
uses: ./.github/workflows/_build_linux.yml
4545
with:
4646
os: ubuntu-latest
4747
arch: x86_64
4848
python-version: "${{ matrix.python-version }}"
49-
run-test: "${{ matrix.python-version == '3.10'}}"
49+
run-test: "${{ matrix.python-version == '3.10' || matrix.python-version == '3.13t' }}"
5050

5151
linux-aarch64:
5252
name: "Linux aarch64"
5353
strategy:
5454
fail-fast: false
5555
matrix:
56-
python-version: ["3.10", "3.11", "3.12", "3.13"]
56+
python-version: ["3.10", "3.11", "3.12", "3.13", "3.13t"]
5757
uses: ./.github/workflows/_build_linux.yml
5858
with:
5959
os: ubuntu-24.04-arm
6060
arch: aarch64
6161
python-version: "${{ matrix.python-version }}"
62-
run-test: "${{ matrix.python-version == '3.10'}}"
62+
run-test: "${{ matrix.python-version == '3.10' || matrix.python-version == '3.13t' }}"
6363

6464
#############################################################################
6565
# Linux (CUDA)
@@ -69,7 +69,7 @@ jobs:
6969
strategy:
7070
fail-fast: false
7171
matrix:
72-
python-version: ["3.10", "3.11", "3.12", "3.13"]
72+
python-version: ["3.10", "3.11", "3.12", "3.13", "3.13t"]
7373
cuda-version: ["12.6"]
7474
uses: ./.github/workflows/_build_linux_cuda.yml
7575
with:
@@ -79,4 +79,4 @@ jobs:
7979
arch: x86_64
8080
python-version: "${{ matrix.python-version }}"
8181
cuda-version: "${{ matrix.cuda-version }}"
82-
run-test: "${{ matrix.python-version == '3.10'}}"
82+
run-test: "${{ matrix.python-version == '3.10' || matrix.python-version == '3.13t' }}"

0 commit comments

Comments
 (0)