Skip to content

Commit 15f79cb

Browse files
committed
Add support for 3.14
Signed-off-by: Bernát Gábor <bgabor8@bloomberg.net>
1 parent 77d02f5 commit 15f79cb

File tree

8 files changed

+266
-230
lines changed

8 files changed

+266
-230
lines changed

.github/workflows/check.yaml

Lines changed: 42 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: check
1+
name: "🛠️ check"
22
on:
33
workflow_dispatch:
44
push:
@@ -14,152 +14,128 @@ concurrency:
1414

1515
jobs:
1616
test:
17-
name: test ${{ matrix.py }} - ${{ matrix.os }}
17+
name: "🧪 Test ${{ matrix.py }} - ${{ matrix.os }}"
1818
runs-on: ${{ matrix.os }}
1919
strategy:
2020
fail-fast: false
2121
matrix:
2222
py:
23-
- "pypy3.10" # ahead to start it earlier because takes longer
23+
- "pypy3.11" # ahead to start it earlier because takes longer
24+
- "3.14"
2425
- "3.13"
2526
- "3.12"
2627
- "3.11"
2728
- "3.10"
2829
- "3.9"
2930
os:
30-
- ubuntu-latest
31-
- windows-latest
32-
- macos-latest
31+
- ubuntu-24.04
32+
- windows-2025
33+
- macos-15
3334

3435
steps:
3536
- uses: actions/checkout@v5
3637
with:
3738
fetch-depth: 0
38-
- name: Install the latest version of uv
39+
- name: "🔄 Install the latest version of uv"
3940
uses: astral-sh/setup-uv@v6
40-
with:
41-
enable-cache: true
42-
cache-dependency-glob: "pyproject.toml"
43-
github-token: ${{ secrets.GITHUB_TOKEN }}
44-
- name: Add .local/bin to Windows PATH
45-
if: runner.os == 'Windows'
46-
shell: bash
47-
run: echo "$USERPROFILE/.local/bin" >> $GITHUB_PATH
48-
- name: Install tox
41+
- name: "🧪 Install tox"
4942
run: uv tool install --python-preference only-managed --python 3.13 tox --with tox-uv
50-
- name: Install Python
43+
- name: "🐍 Install Python"
5144
run: uv python install --python-preference only-managed ${{ matrix.py }}
52-
- name: Setup test suite
45+
- name: "⚙️ Setup test suite"
5346
run: tox run -vv --notest --skip-missing-interpreters false -e ${{ matrix.py }}
5447
env:
5548
UV_PYTHON_PREFERENCE: only-managed
56-
- name: Run test suite
57-
if: ${{ !startsWith(matrix.py, 'pypy')}}
58-
run: tox run --skip-pkg-install -e ${{ matrix.py }}
59-
env:
60-
PYTEST_ADDOPTS: "-vv --durations=20"
61-
DIFF_AGAINST: HEAD
62-
UV_PYTHON_PREFERENCE: only-managed
63-
- name: Run test suite without coverage
64-
if: ${{ startsWith(matrix.py, 'pypy')}}
65-
run: tox run --skip-pkg-install -e ${{ matrix.py }} --
49+
- name: "✅ Run test suite"
50+
run: |
51+
if [[ "${{ matrix.py }}" == pypy* ]]; then
52+
tox run --skip-pkg-install -e ${{ matrix.py }} --
53+
else
54+
tox run --skip-pkg-install -e ${{ matrix.py }}
55+
fi
56+
shell: bash
6657
env:
6758
PYTEST_ADDOPTS: "-vv --durations=20"
6859
UV_PYTHON_PREFERENCE: only-managed
69-
- name: Rename coverage report file
60+
DIFF_AGAINST: HEAD
61+
- name: "📝 Rename coverage report file"
7062
if: ${{ !startsWith(matrix.py, 'pypy')}}
7163
run: |
7264
import os; import sys
7365
os.rename(f".tox/.coverage.${{ matrix.py }}", f".tox/.coverage.${{ matrix.py }}-{sys.platform}")
7466
shell: python
75-
- name: Upload coverage data
67+
- name: "📦 Upload coverage data"
7668
if: ${{ !startsWith(matrix.py, 'pypy')}}
7769
uses: actions/upload-artifact@v4
7870
with:
7971
include-hidden-files: true
8072
name: .coverage.${{ matrix.os }}.${{ matrix.py }}
81-
path: ".tox/.coverage.*"
73+
path: ".tox/*/tmp/.coverage.*"
8274
retention-days: 3
8375

8476
coverage:
85-
name: Combine coverage
86-
runs-on: ubuntu-latest
77+
name: "📊 Combine coverage"
78+
runs-on: ubuntu-24.04
8779
needs: test
8880
steps:
8981
- uses: actions/checkout@v5
9082
with:
9183
fetch-depth: 0
92-
- name: Install the latest version of uv
84+
- name: "🔄 Install the latest version of uv"
9385
uses: astral-sh/setup-uv@v6
94-
with:
95-
enable-cache: true
96-
cache-dependency-glob: "pyproject.toml"
97-
github-token: ${{ secrets.GITHUB_TOKEN }}
98-
- name: Add .local/bin to Windows PATH
99-
if: runner.os == 'Windows'
100-
shell: bash
101-
run: echo "$USERPROFILE/.local/bin" >> $GITHUB_PATH
102-
- name: Install hatch
86+
- name: "🧪 Install hatch"
10387
run: uv tool install --python-preference only-managed --python 3.13 tox --with tox-uv
104-
- name: Build package to generate version
88+
- name: "📦 Build package to generate version"
10589
run: uv build --python 3.13 --python-preference only-managed --wheel . --out-dir dist
106-
- name: Setup coverage tool
90+
- name: "⚙️ Setup coverage tool"
10791
run: tox -e coverage --notest
10892
env:
10993
UV_PYTHON_PREFERENCE: only-managed
110-
- name: Download coverage data
94+
- name: "⬇️ Download coverage data"
11195
uses: actions/download-artifact@v5
11296
with:
11397
path: .tox
11498
pattern: .coverage.*
11599
merge-multiple: true
116-
- name: Combine and report coverage
100+
- name: "📊 Combine and report coverage"
117101
run: tox -e coverage --skip-pkg-install
118102
env:
119103
UV_PYTHON_PREFERENCE: only-managed
120-
- name: Upload HTML report
104+
- name: "📤 Upload HTML report"
121105
uses: actions/upload-artifact@v4
122106
with:
123107
name: html-report
124-
path: .tox/htmlcov
108+
path: .tox/coverage/tmp/htmlcov
125109

126110
check:
127-
name: ${{ matrix.tox_env }} - ${{ matrix.os }}
111+
name: "🔎 ${{ matrix.tox_env }} - ${{ matrix.os }}"
128112
runs-on: ${{ matrix.os }}
129113
strategy:
130114
fail-fast: false
131115
matrix:
132116
os:
133-
- ubuntu-latest
134-
- windows-latest
117+
- ubuntu-24.04
118+
- windows-2025
135119
tox_env:
136120
- dev
137121
- type
138122
- docs
139-
- readme
123+
- pkg_meta
140124
exclude:
141-
- { os: windows-latest, tox_env: readme }
125+
- { os: windows-2025, tox_env: pkg_meta }
142126
steps:
143127
- uses: actions/checkout@v5
144128
with:
145129
fetch-depth: 0
146-
- name: Install the latest version of uv
130+
- name: "🔄 Install the latest version of uv"
147131
uses: astral-sh/setup-uv@v6
148-
with:
149-
enable-cache: true
150-
cache-dependency-glob: "pyproject.toml"
151-
github-token: ${{ secrets.GITHUB_TOKEN }}
152-
- name: Add .local/bin to Windows PATH
153-
if: runner.os == 'Windows'
154-
shell: bash
155-
run: echo "$USERPROFILE/.local/bin" >> $GITHUB_PATH
156-
- name: Install tox
132+
- name: "🧪 Install tox"
157133
run: uv tool install --python-preference only-managed --python 3.13 tox --with tox-uv
158-
- name: Setup test suite
134+
- name: "⚙️ Setup test suite"
159135
run: tox run -vv --notest --skip-missing-interpreters false -e ${{ matrix.tox_env }}
160136
env:
161137
UV_PYTHON_PREFERENCE: only-managed
162-
- name: Run test suite
138+
- name: "Run test suite"
163139
run: tox run --skip-pkg-install -e ${{ matrix.tox_env }}
164140
env:
165141
UV_PYTHON_PREFERENCE: only-managed

.github/workflows/release.yaml

Lines changed: 9 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Release to PyPI
1+
name: 🚀Release to PyPI
22
on:
33
push:
44
tags: ["*"]
@@ -8,20 +8,16 @@ env:
88

99
jobs:
1010
build:
11-
runs-on: ubuntu-latest
11+
runs-on: ubuntu-24.04
1212
steps:
1313
- uses: actions/checkout@v5
1414
with:
1515
fetch-depth: 0
16-
- name: Install the latest version of uv
16+
- name: "🔄 Install the latest version of uv"
1717
uses: astral-sh/setup-uv@v6
18-
with:
19-
enable-cache: true
20-
cache-dependency-glob: "pyproject.toml"
21-
github-token: ${{ secrets.GITHUB_TOKEN }}
22-
- name: Build package
18+
- name: "📦 Build package"
2319
run: uv build --python 3.13 --python-preference only-managed --sdist --wheel . --out-dir dist
24-
- name: Store the distribution packages
20+
- name: "📤 Store the distribution packages"
2521
uses: actions/upload-artifact@v4
2622
with:
2723
name: ${{ env.dists-artifact-name }}
@@ -30,19 +26,17 @@ jobs:
3026
release:
3127
needs:
3228
- build
33-
runs-on: ubuntu-latest
29+
runs-on: ubuntu-24.04
3430
environment:
35-
name: release
31+
name: "🚀 Release to PyPI"
3632
url: https://pypi.org/project/filelock/${{ github.ref_name }}
3733
permissions:
3834
id-token: write
3935
steps:
40-
- name: Download all the dists
36+
- name: "⬇️ Download all the dists"
4137
uses: actions/download-artifact@v5
4238
with:
4339
name: ${{ env.dists-artifact-name }}
4440
path: dist/
45-
- name: Publish to PyPI
41+
- name: "🚀 Publish to PyPI"
4642
uses: pypa/gh-action-pypi-publish@v1.12.4
47-
with:
48-
attestations: true

.pre-commit-config.yaml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,10 @@ repos:
1414
hooks:
1515
- id: codespell
1616
additional_dependencies: ["tomli>=2.2.1"]
17-
- repo: https://github.com/tox-dev/tox-ini-fmt
18-
rev: "1.6.0"
17+
- repo: https://github.com/tox-dev/tox-toml-fmt
18+
rev: "v1.0.0"
1919
hooks:
20-
- id: tox-ini-fmt
21-
args: ["-p", "fix"]
20+
- id: tox-toml-fmt
2221
- repo: https://github.com/tox-dev/pyproject-fmt
2322
rev: "v2.6.0"
2423
hooks:
@@ -34,8 +33,8 @@ repos:
3433
hooks:
3534
- id: prettier
3635
additional_dependencies:
37-
- prettier@3.4.2
38-
- "@prettier/plugin-xml@3.4.1"
36+
- prettier@3.6.2
37+
- "@prettier/plugin-xml@3.4.2"
3938
- repo: meta
4039
hooks:
4140
- id: check-hooks-apply

.readthedocs.yml

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,10 @@
11
version: 2
22
build:
3-
os: ubuntu-22.04
3+
os: ubuntu-lts-latest
44
tools:
55
python: "3"
6-
python:
7-
install:
8-
- method: pip
9-
path: .
10-
extra_requirements:
11-
- docs
12-
sphinx:
13-
builder: html
14-
configuration: docs/conf.py
15-
fail_on_warning: true
6+
commands:
7+
- pip install uv
8+
- uv venv
9+
- uv pip install tox-uv
10+
- .venv/bin/tox run -e docs --

0 commit comments

Comments
 (0)