From 591181f65432fccf2358cf98bcadefd883439289 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bern=C3=A1t=20G=C3=A1bor?= Date: Fri, 9 Oct 2026 15:36:09 -0700 Subject: [PATCH 1/2] feat(python): default to Python 3.15 --- .github/workflows/check.yaml | 5 ++--- .github/workflows/release.yaml | 2 +- .pre-commit-config.yaml | 2 ++ pyproject.toml | 41 +++++++++++++++++----------------- tox.toml | 6 ++++- 5 files changed, 30 insertions(+), 26 deletions(-) diff --git a/.github/workflows/check.yaml b/.github/workflows/check.yaml index 1c430bc..f4ba37a 100644 --- a/.github/workflows/check.yaml +++ b/.github/workflows/check.yaml @@ -28,7 +28,6 @@ jobs: - "3.13" - "3.12" - "3.11" - - "3.10" - type - dev - pkg_meta @@ -43,9 +42,9 @@ jobs: enable-cache: false cache-dependency-glob: "pyproject.toml" - name: Install tox - run: uv tool install --python-preference only-managed --python 3.14 tox --with tox-uv + run: uv tool install --python-preference only-managed --python 3.15 tox --with tox-uv - name: Install Python - if: startsWith(matrix.env, '3.') && matrix.env != '3.14' + if: startsWith(matrix.env, '3.') && matrix.env != '3.15' run: uv python install --python-preference only-managed ${{ matrix.env }} - name: Setup test suite run: tox run -vv --notest --skip-missing-interpreters false -e ${{ matrix.env }} diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 8968690..d232162 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -24,7 +24,7 @@ jobs: cache-dependency-glob: "pyproject.toml" github-token: ${{ secrets.GITHUB_TOKEN }} - name: Build package - run: uv build --python 3.14 --python-preference only-managed --sdist --wheel . --out-dir dist + run: uv build --python 3.15 --python-preference only-managed --sdist --wheel . --out-dir dist - name: Store the distribution packages uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 with: diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 9f1bd6a..785b797 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,3 +1,5 @@ +default_language_version: + python: python3.15 repos: - repo: https://github.com/pre-commit/pre-commit-hooks rev: v6.0.0 diff --git a/pyproject.toml b/pyproject.toml index 7867aa5..866977d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -17,13 +17,12 @@ license.file = "LICENSE.txt" authors = [ { name = "Bernat Gabor", email = "gaborjbernat@gmail.com" }, ] -requires-python = ">=3.10" +requires-python = ">=3.11" classifiers = [ "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.13", @@ -90,26 +89,26 @@ lint.select = [ "ALL", ] lint.ignore = [ - "ANN401", # allow Any as type annotation - "COM812", # Conflict with formatter - "CPY", # No copyright statements - "D203", # `one-blank-line-before-class` (D203) and `no-blank-line-before-class` (D211) are incompatible - "D212", # `multi-line-summary-first-line` (D212) and `multi-line-summary-second-line` (D213) are incompatible - "DOC501", # not working with Sphinx - "ISC001", # Conflict with formatter - "RUF067", # `__init__` module should only contain docstrings and re-exports - "S104", # Possible binding to all interfaces + "any-type", # allow Any as type annotation + "CPY", # No copyright statements + "docstring-missing-exception", # not working with Sphinx + "hardcoded-bind-all-interfaces", # Possible binding to all interfaces + "incorrect-blank-line-before-class", # `one-blank-line-before-class` (D203) and `no-blank-line-before-class` (D211) are incompatible + "missing-trailing-comma", # Conflict with formatter + "multi-line-summary-first-line", # `multi-line-summary-first-line` (D212) and `multi-line-summary-second-line` (D213) are incompatible + "non-empty-init-module", # `__init__` module should only contain docstrings and re-exports + "single-line-implicit-string-concatenation", # Conflict with formatter ] lint.per-file-ignores."tests/**/*.py" = [ - "D", # don"t care about documentation in tests - "FBT", # don"t care about booleans as positional arguments in tests - "INP001", # no implicit namespace - "PLC2701", # private import - "PLR0913", # any number of arguments in tests - "PLR0917", # any number of arguments in tests - "PLR2004", # Magic value used in comparison, consider replacing with a constant variable - "S", # `subprocess` call: check for execution of untrusted input - "S101", # asserts allowed in tests... + "assert", # asserts allowed in tests... + "D", # don"t care about documentation in tests + "FBT", # don"t care about booleans as positional arguments in tests + "implicit-namespace-package", # no implicit namespace + "import-private-name", # private import + "magic-value-comparison", # Magic value used in comparison, consider replacing with a constant variable + "S", # `subprocess` call: check for execution of untrusted input + "too-many-arguments", # any number of arguments in tests + "too-many-positional-arguments", # any number of arguments in tests ] lint.isort = { known-first-party = [ "pre_commit_uv", @@ -126,7 +125,7 @@ count = true max_supported_python = "3.15" [tool.ty] -environment.python-version = "3.14" +environment.python-version = "3.15" [tool.pytest] ini_options.testpaths = [ diff --git a/tox.toml b/tox.toml index b761369..6034a7e 100644 --- a/tox.toml +++ b/tox.toml @@ -1,9 +1,10 @@ requires = [ "tox>=4.64.7", "tox-uv>=1.36.1" ] -env_list = [ "3.15", "3.14", "3.13", "3.12", "3.11", "3.10", "3.9", "3.8", "3.15t", "fix", "pkg_meta", "type" ] +env_list = [ "3.15", "3.14", "3.13", "3.12", "3.11", "3.15t", "fix", "pkg_meta", "type" ] skip_missing_interpreters = true [env_run_base] description = "run the unit tests with pytest under {env_name}" +default_base_python = [ "3.15" ] package = "wheel" wheel_build_env = ".pkg" dependency_groups = [ "test" ] @@ -35,6 +36,9 @@ commands = [ ], ] +[env_pkg_base] +default_base_python = [ "3.15" ] + [env.fix] description = "format the code base to adhere to our styles, and complain about what we cannot do automatically" skip_install = true From 17dacb35380340cda23a43538694754fc8b7a3a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bern=C3=A1t=20G=C3=A1bor?= Date: Fri, 9 Oct 2026 16:14:53 -0700 Subject: [PATCH 2/2] feat(ci): default uv to Python 3.15 --- .github/workflows/check.yaml | 1 + .github/workflows/release.yaml | 1 + 2 files changed, 2 insertions(+) diff --git a/.github/workflows/check.yaml b/.github/workflows/check.yaml index f4ba37a..f6d7b54 100644 --- a/.github/workflows/check.yaml +++ b/.github/workflows/check.yaml @@ -39,6 +39,7 @@ jobs: - name: Install the latest version of uv uses: astral-sh/setup-uv@c18668ad3cf93ea998bef934396af7bb5c839dc7 # v10.2.0 with: + python-version: "3.15" enable-cache: false cache-dependency-glob: "pyproject.toml" - name: Install tox diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index d232162..d811f7f 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -20,6 +20,7 @@ jobs: - name: Install the latest version of uv uses: astral-sh/setup-uv@c18668ad3cf93ea998bef934396af7bb5c839dc7 # v10.2.0 with: + python-version: "3.15" enable-cache: false cache-dependency-glob: "pyproject.toml" github-token: ${{ secrets.GITHUB_TOKEN }}