Skip to content

Commit 15eea06

Browse files
committed
fix: set ruff target-version to py39 (minimum supported version)
With target-version py314, ruff format applies PEP 758 (parentheses-free except clauses), which is invalid syntax on Python < 3.14. Since the project supports Python 3.9+, the target must match the minimum version to prevent incompatible syntax in formatted code.
1 parent f009179 commit 15eea06

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

AGENTS.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ uv run mypy statemachine/ tests/
7272

7373
## Code style
7474

75-
- **Formatter/Linter:** ruff (line length 99, target Python 3.14)
75+
- **Formatter/Linter:** ruff (line length 99, target Python 3.9)
7676
- **Rules:** pycodestyle, pyflakes, isort, pyupgrade, flake8-comprehensions, flake8-bugbear, flake8-pytest-style
7777
- **Imports:** single-line, sorted by isort
7878
- **Docstrings:** Google convention

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ ignore_missing_imports = true
134134
src = ["statemachine"]
135135

136136
line-length = 99
137-
target-version = "py314"
137+
target-version = "py39"
138138

139139
# Exclude a variety of commonly ignored directories.
140140
exclude = [

0 commit comments

Comments
 (0)