Skip to content

Commit 2d8246e

Browse files
authored
ci: fix CI (drop Python 3.9, tokio 1.53.3, regenerate third-party licenses) (#389)
* ci: drop Python 3.9 support Python 3.9 is end-of-life, and ubuntu-latest (26.04) no longer has a 3.9 build for actions/setup-python, which failed the 3.9 job and cancelled the rest of the matrix. Raise requires-python to >=3.10, drop the 3.9 classifier, target abi3-py310, and remove 3.9 from the hatch and CI matrices. Signed-off-by: Sean Tang <171081544+seant-aws@users.noreply.github.com> * fix: update tokio to 1.53.3 for RUSTSEC-2026-0386 cargo-deny's advisories check fails on RUSTSEC-2026-0386 (unsound safe AsyncFd constructors) for tokio 1.53.1. 1.53.3 is the patched release on the same minor line. Lockfile-only update; the matching tokio line in THIRD-PARTY-LICENSES.txt is updated so the license check stays in sync with Cargo.lock. Signed-off-by: Sean Tang <171081544+seant-aws@users.noreply.github.com> * chore: regenerate THIRD-PARTY-LICENSES.txt New pydantic, pydantic_core and typing-inspection releases put the committed file out of date. Regenerated with scripts/check_third_party_licenses.sh --update; only version lines changed. Signed-off-by: Sean Tang <171081544+seant-aws@users.noreply.github.com> --------- Signed-off-by: Sean Tang <171081544+seant-aws@users.noreply.github.com>
1 parent 1eaa3c0 commit 2d8246e

12 files changed

Lines changed: 22 additions & 27 deletions

File tree

‎.github/workflows/code_quality.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
strategy:
1919
matrix:
2020
os: [ubuntu-latest, windows-latest, macos-latest]
21-
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13', '3.14']
21+
python-version: ['3.10', '3.11', '3.12', '3.13', '3.14']
2222
uses: OpenJobDescription/.github/.github/workflows/reusable_python_build.yml@mainline
2323
with:
2424
os: ${{ matrix.os }}

‎AGENTS.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ cargo test --manifest-path rust-bindings/Cargo.toml
3939
cargo test --manifest-path rust-bindings/Cargo.toml --doc
4040
```
4141

42-
Python: **3.9+** (declared via `abi3-py39` in `rust-bindings/Cargo.toml`, enforced by `pyproject.toml` `requires-python`).
42+
Python: **3.10+** (declared via `abi3-py310` in `rust-bindings/Cargo.toml`, enforced by `pyproject.toml` `requires-python`).
4343

4444
## Component Map
4545

@@ -199,7 +199,7 @@ Items the `eval-bindings` skill checks; these are the recurring sources of behav
199199
- **Type conversions** — `IntoPyObject`/`FromPyObject` impls must preserve types faithfully. Watch the `int` ↔ `i64`/`u64` boundary, `float` NaN/Inf passthrough, `pathlib.Path` ↔ `Path`/`PathBuf`, and ordered vs unordered collections.
200200
- **GIL handling** — long-running Rust calls (sessions subprocess wait, large template parses) should release the GIL via `Python::allow_threads`. Holding the GIL across blocking I/O blocks every other Python thread.
201201
- **`#[pyclass]` constructor signatures** — Python `__init__` signatures must match what the spec advertises. Keep `#[pyo3(signature = ...)]` aligned with `text_signature` and the spec.
202-
- **ABI3 compatibility** — `Cargo.toml` declares `abi3-py39`. Don't introduce code that uses Python C-API features beyond ABI3.
202+
- **ABI3 compatibility** — `Cargo.toml` declares `abi3-py310`. Don't introduce code that uses Python C-API features beyond ABI3.
203203
- **Stub generation** — `scripts/generate_stubs.sh` runs the `stub_gen` binary and produces `src/openjd/_openjd_rs.pyi`. The stub must match the bindings; regenerate it whenever you change a public symbol's signature.
204204

205205
### Coding Style
@@ -215,7 +215,7 @@ PRs run these checks (all must pass):
215215

216216
| Workflow | What it does |
217217
|----------|--------------|
218-
| **Code Quality** (`code_quality.yml`) | Python build + tests on `{ubuntu, windows, macos} × {3.9, 3.10, 3.11, 3.12, 3.13, 3.14}`. Uses the shared `OpenJobDescription/.github` reusable workflow, which runs `hatch run lint`, `hatch run typing`, and `hatch run test`. Transitively builds the Rust extension via the `maturin develop` step in `hatch.toml`. |
218+
| **Code Quality** (`code_quality.yml`) | Python build + tests on `{ubuntu, windows, macos} × {3.10, 3.11, 3.12, 3.13, 3.14}`. Uses the shared `OpenJobDescription/.github` reusable workflow, which runs `hatch run lint`, `hatch run typing`, and `hatch run test`. Transitively builds the Rust extension via the `maturin develop` step in `hatch.toml`. |
219219
| **Rust Quality** (`rust_quality.yml`) | `cargo build --all-targets`, `cargo clippy --all-targets -- -D warnings` (hard gate), `cargo test`, and `cargo test --doc` against `rust-bindings/`. Runs on `{ubuntu, windows, macos}`. Resolves `openjd-*` dependencies from crates.io at the versions pinned in `rust-bindings/Cargo.toml`. |
220220
| **CodeQL** (`codeql.yml`) | GitHub's static analysis. |
221221
| **PR opened/responded/auto_approve/stale_prs_and_issues/record_pr** | Repo housekeeping; not relevant to code changes. |

‎Cargo.lock‎

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎DEVELOPMENT.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Table of Contents:
1616

1717
To develop the Python code in this repository you will need:
1818

19-
1. Python 3.9 or higher. We recommend [mise](https://github.com/jdx/mise) if you would like to run more than one version
19+
1. Python 3.10 or higher. We recommend [mise](https://github.com/jdx/mise) if you would like to run more than one version
2020
of Python on the same system. When running unit tests against all supported Python versions, for instance.
2121
2. The [hatch](https://github.com/pypa/hatch) package installed (`pip install --upgrade hatch`) into your Python environment.
2222

‎README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ Open Job Description [Wiki on GitHub](https://github.com/OpenJobDescription/open
1818

1919
This library requires:
2020

21-
1. Python 3.9 or higher; and
21+
1. Python 3.10 or higher; and
2222
2. Linux, MacOS, or Windows operating system.
2323

2424
## Versioning

‎THIRD-PARTY-LICENSES.txt‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2424
SOFTWARE.
2525

2626
------
27-
** pydantic; version 2.14.1 -- https://pypi.org/project/pydantic/
27+
** pydantic; version 2.14.3 -- https://pypi.org/project/pydantic/
2828
The MIT License (MIT)
2929

3030
Copyright (c) 2017 to present Pydantic Services Inc. and individual contributors.
@@ -48,7 +48,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
4848
SOFTWARE.
4949

5050
------
51-
** pydantic_core; version 2.50.1 -- https://pypi.org/project/pydantic_core/
51+
** pydantic_core; version 2.50.4 -- https://pypi.org/project/pydantic_core/
5252
The MIT License (MIT)
5353

5454
Copyright (c) 2022 Samuel Colvin
@@ -95,7 +95,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
9595
SOFTWARE.
9696

9797
------
98-
** typing-inspection; version 0.4.4 -- https://pypi.org/project/typing-inspection/
98+
** typing-inspection; version 0.4.5 -- https://pypi.org/project/typing-inspection/
9999
MIT License
100100

101101
Copyright (c) Pydantic Services Inc. 2025 to present
@@ -3239,7 +3239,7 @@ USE OR OTHER DEALINGS IN THE SOFTWARE.
32393239

32403240
------
32413241
** tokio-util; version 0.7.19 -- https://crates.io/crates/tokio-util
3242-
** tokio; version 1.53.1 -- https://crates.io/crates/tokio
3242+
** tokio; version 1.53.3 -- https://crates.io/crates/tokio
32433243
MIT License
32443244

32453245
Copyright (c) Tokio Contributors

‎hatch.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ lint = [
3131
]
3232

3333
[[envs.all.matrix]]
34-
python = ["3.9", "3.10", "3.11", "3.12"]
34+
python = ["3.10", "3.11", "3.12"]
3535

3636
[envs.release]
3737
detached = true

‎pyproject.toml‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,13 @@ authors = [
1515
dynamic = ["version"]
1616
readme = "README.md"
1717
license = "Apache-2.0"
18-
requires-python = ">=3.9"
18+
requires-python = ">=3.10"
1919
description = "Provides a Python implementation of the data model for Open Job Description's template schemas."
2020
# https://pypi.org/classifiers/
2121
classifiers = [
2222
"Development Status :: 5 - Production/Stable",
2323
"Programming Language :: Python",
2424
"Programming Language :: Python :: 3 :: Only",
25-
"Programming Language :: Python :: 3.9",
2625
"Programming Language :: Python :: 3.10",
2726
"Programming Language :: Python :: 3.11",
2827
"Programming Language :: Python :: 3.12",

‎requirements-testing.txt‎

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,17 @@
11
coverage[toml] == 7.*
2-
pytest == 9.1.*; python_version >= "3.10"
3-
pytest == 8.4.*; python_version < "3.10"
2+
pytest == 9.1.*
43
pytest-cov == 7.1.*
54
pytest-timeout == 2.4.*
65
pytest-xdist == 3.8.*
76
types-PyYAML ~= 6.0
87
# Pinned to 25.x because black 26+ produces different formatting output
98
# that is incompatible with black 25 (last version supporting Python 3.9).
10-
black == 25.12.*; python_version >= "3.10"
11-
black == 25.11.*; python_version < "3.10"
9+
black == 25.12.*
1210
ruff == 0.15.*
13-
mypy == 2.3.*; python_version >= "3.10"
14-
mypy == 1.19.*; python_version < "3.10"
11+
mypy == 2.3.*
1512
# pydantic: required by the legacy model_v0 (Pydantic) test suite,
1613
# which lives alongside the new Rust-backed model_v1 implementation.
1714
pydantic >= 2.10, < 3
1815
# hypothesis: used by the opt-in fuzz test suites in test/openjd/expr
1916
# and test/openjd/model-v*. conftest.py imports it unconditionally.
20-
hypothesis ~= 6.161; python_version >= "3.10"
21-
hypothesis ~= 6.141; python_version < "3.10"
17+
hypothesis ~= 6.161

‎rust-bindings/Cargo.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ openjd-sessions = "0.8.1"
1818
tokio = { version = "1", features = ["rt-multi-thread"] }
1919
uuid = { version = "1", features = ["v4"] }
2020
serde_json = "1"
21-
pyo3 = { version = "0.29.3", features = ["abi3-py39"] }
21+
pyo3 = { version = "0.29.3", features = ["abi3-py310"] }
2222
pyo3-log = "0.13"
2323
log = "0.4"
2424
pyo3-stub-gen = { version = "0.23", optional = true }

0 commit comments

Comments
 (0)