From 2ab5bbef5afea526575efced4f5e9fc7d424057c Mon Sep 17 00:00:00 2001 From: Russ Allbery Date: Mon, 5 Jan 2026 14:27:03 -0800 Subject: [PATCH] Update FastAPI Safir app template to Python 3.14 Update the FastAPI Safir app template to Python 3.14 and bump the versions of uv and the pre-commit hooks. --- .../fastapi_safir_app/example-uws/.github/workflows/ci.yaml | 2 +- .../example-uws/.github/workflows/periodic-ci.yaml | 2 +- .../fastapi_safir_app/example-uws/.pre-commit-config.yaml | 4 ++-- .../fastapi_safir_app/example-uws/.python-version | 2 +- project_templates/fastapi_safir_app/example-uws/Dockerfile | 4 ++-- .../fastapi_safir_app/example-uws/pyproject.toml | 6 +++--- .../fastapi_safir_app/example/.github/workflows/ci.yaml | 2 +- .../example/.github/workflows/periodic-ci.yaml | 2 +- .../fastapi_safir_app/example/.pre-commit-config.yaml | 4 ++-- project_templates/fastapi_safir_app/example/.python-version | 2 +- project_templates/fastapi_safir_app/example/Dockerfile | 4 ++-- project_templates/fastapi_safir_app/example/pyproject.toml | 6 +++--- .../{{cookiecutter.name}}/.github/workflows/ci.yaml | 2 +- .../.github/workflows/periodic-ci.yaml | 2 +- .../{{cookiecutter.name}}/.pre-commit-config.yaml | 4 ++-- .../fastapi_safir_app/{{cookiecutter.name}}/.python-version | 2 +- .../fastapi_safir_app/{{cookiecutter.name}}/Dockerfile | 4 ++-- .../fastapi_safir_app/{{cookiecutter.name}}/pyproject.toml | 6 +++--- project_templates/technote_md/testn-000/technote.toml | 2 +- project_templates/technote_rst/testn-000/technote.toml | 2 +- 20 files changed, 32 insertions(+), 32 deletions(-) diff --git a/project_templates/fastapi_safir_app/example-uws/.github/workflows/ci.yaml b/project_templates/fastapi_safir_app/example-uws/.github/workflows/ci.yaml index 2b813ff7..494cd42c 100644 --- a/project_templates/fastapi_safir_app/example-uws/.github/workflows/ci.yaml +++ b/project_templates/fastapi_safir_app/example-uws/.github/workflows/ci.yaml @@ -4,7 +4,7 @@ env: # Current supported uv version. The uv documentation recommends pinning # this. The version should match the version used in .pre-commit-config.yaml # and frozen in uv.lock. It is updated by make update-deps. - UV_VERSION: "0.8.19" + UV_VERSION: "0.9.21" "on": merge_group: {} diff --git a/project_templates/fastapi_safir_app/example-uws/.github/workflows/periodic-ci.yaml b/project_templates/fastapi_safir_app/example-uws/.github/workflows/periodic-ci.yaml index 9ea1ed2c..e2fc8a42 100644 --- a/project_templates/fastapi_safir_app/example-uws/.github/workflows/periodic-ci.yaml +++ b/project_templates/fastapi_safir_app/example-uws/.github/workflows/periodic-ci.yaml @@ -9,7 +9,7 @@ env: # Current supported uv version. The uv documentation recommends pinning # this. The version should match the version used in .pre-commit-config.yaml # and frozen in uv.lock. It is updated by make update-deps. - UV_VERSION: "0.8.19" + UV_VERSION: "0.9.21" "on": schedule: diff --git a/project_templates/fastapi_safir_app/example-uws/.pre-commit-config.yaml b/project_templates/fastapi_safir_app/example-uws/.pre-commit-config.yaml index 11b03b1a..2e09a239 100644 --- a/project_templates/fastapi_safir_app/example-uws/.pre-commit-config.yaml +++ b/project_templates/fastapi_safir_app/example-uws/.pre-commit-config.yaml @@ -7,13 +7,13 @@ repos: - id: trailing-whitespace - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.13.1 + rev: v0.14.10 hooks: - id: ruff-check args: [--fix, --exit-non-zero-on-fix] - id: ruff-format - repo: https://github.com/astral-sh/uv-pre-commit - rev: 0.8.19 + rev: 0.9.21 hooks: - id: uv-lock diff --git a/project_templates/fastapi_safir_app/example-uws/.python-version b/project_templates/fastapi_safir_app/example-uws/.python-version index 24ee5b1b..6324d401 100644 --- a/project_templates/fastapi_safir_app/example-uws/.python-version +++ b/project_templates/fastapi_safir_app/example-uws/.python-version @@ -1 +1 @@ -3.13 +3.14 diff --git a/project_templates/fastapi_safir_app/example-uws/Dockerfile b/project_templates/fastapi_safir_app/example-uws/Dockerfile index d3d6fe1e..b5a2dd08 100644 --- a/project_templates/fastapi_safir_app/example-uws/Dockerfile +++ b/project_templates/fastapi_safir_app/example-uws/Dockerfile @@ -11,7 +11,7 @@ # - Runs a non-root user. # - Sets up the entrypoint and port. -FROM python:3.13.7-slim-trixie AS base-image +FROM python:3.14.2-slim-trixie AS base-image # Update system packages. COPY scripts/install-base-packages.sh . @@ -22,7 +22,7 @@ RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \ FROM base-image AS install-image # Install uv. -COPY --from=ghcr.io/astral-sh/uv:0.8.19 /uv /bin/uv +COPY --from=ghcr.io/astral-sh/uv:0.9.21 /uv /bin/uv # Install system packages only needed for building dependencies. COPY scripts/install-dependency-packages.sh . diff --git a/project_templates/fastapi_safir_app/example-uws/pyproject.toml b/project_templates/fastapi_safir_app/example-uws/pyproject.toml index 4904e61d..460ee0ca 100644 --- a/project_templates/fastapi_safir_app/example-uws/pyproject.toml +++ b/project_templates/fastapi_safir_app/example-uws/pyproject.toml @@ -11,13 +11,13 @@ classifiers = [ "Development Status :: 4 - Beta", "Programming Language :: Python", "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.13", + "Programming Language :: Python :: 3.14", "Natural Language :: English", "Operating System :: POSIX", "Private :: Do Not Upload", "Typing :: Typed", ] -requires-python = ">=3.13" +requires-python = ">=3.14" dependencies = [ "fastapi>=0.100", "pydantic>2", @@ -32,7 +32,7 @@ Homepage = "https://example-uws.lsst.io" Source = "https://github.com/lsst-sqre/example-uws" [build-system] -requires = ["setuptools>=61", "wheel", "setuptools_scm[toml]>=6.2"] +requires = ["setuptools>=61", "setuptools_scm[toml]>=6.2"] build-backend = "setuptools.build_meta" [dependency-groups] diff --git a/project_templates/fastapi_safir_app/example/.github/workflows/ci.yaml b/project_templates/fastapi_safir_app/example/.github/workflows/ci.yaml index 780f06ab..41d505dc 100644 --- a/project_templates/fastapi_safir_app/example/.github/workflows/ci.yaml +++ b/project_templates/fastapi_safir_app/example/.github/workflows/ci.yaml @@ -4,7 +4,7 @@ env: # Current supported uv version. The uv documentation recommends pinning # this. The version should match the version used in .pre-commit-config.yaml # and frozen in uv.lock. It is updated by make update-deps. - UV_VERSION: "0.8.19" + UV_VERSION: "0.9.21" "on": merge_group: {} diff --git a/project_templates/fastapi_safir_app/example/.github/workflows/periodic-ci.yaml b/project_templates/fastapi_safir_app/example/.github/workflows/periodic-ci.yaml index 9ea1ed2c..e2fc8a42 100644 --- a/project_templates/fastapi_safir_app/example/.github/workflows/periodic-ci.yaml +++ b/project_templates/fastapi_safir_app/example/.github/workflows/periodic-ci.yaml @@ -9,7 +9,7 @@ env: # Current supported uv version. The uv documentation recommends pinning # this. The version should match the version used in .pre-commit-config.yaml # and frozen in uv.lock. It is updated by make update-deps. - UV_VERSION: "0.8.19" + UV_VERSION: "0.9.21" "on": schedule: diff --git a/project_templates/fastapi_safir_app/example/.pre-commit-config.yaml b/project_templates/fastapi_safir_app/example/.pre-commit-config.yaml index 11b03b1a..2e09a239 100644 --- a/project_templates/fastapi_safir_app/example/.pre-commit-config.yaml +++ b/project_templates/fastapi_safir_app/example/.pre-commit-config.yaml @@ -7,13 +7,13 @@ repos: - id: trailing-whitespace - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.13.1 + rev: v0.14.10 hooks: - id: ruff-check args: [--fix, --exit-non-zero-on-fix] - id: ruff-format - repo: https://github.com/astral-sh/uv-pre-commit - rev: 0.8.19 + rev: 0.9.21 hooks: - id: uv-lock diff --git a/project_templates/fastapi_safir_app/example/.python-version b/project_templates/fastapi_safir_app/example/.python-version index 24ee5b1b..6324d401 100644 --- a/project_templates/fastapi_safir_app/example/.python-version +++ b/project_templates/fastapi_safir_app/example/.python-version @@ -1 +1 @@ -3.13 +3.14 diff --git a/project_templates/fastapi_safir_app/example/Dockerfile b/project_templates/fastapi_safir_app/example/Dockerfile index 8b4355c3..e5fce9cd 100644 --- a/project_templates/fastapi_safir_app/example/Dockerfile +++ b/project_templates/fastapi_safir_app/example/Dockerfile @@ -11,7 +11,7 @@ # - Runs a non-root user. # - Sets up the entrypoint and port. -FROM python:3.13.7-slim-trixie AS base-image +FROM python:3.14.2-slim-trixie AS base-image # Update system packages. COPY scripts/install-base-packages.sh . @@ -22,7 +22,7 @@ RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \ FROM base-image AS install-image # Install uv. -COPY --from=ghcr.io/astral-sh/uv:0.8.19 /uv /bin/uv +COPY --from=ghcr.io/astral-sh/uv:0.9.21 /uv /bin/uv # Install system packages only needed for building dependencies. COPY scripts/install-dependency-packages.sh . diff --git a/project_templates/fastapi_safir_app/example/pyproject.toml b/project_templates/fastapi_safir_app/example/pyproject.toml index 0bd202c8..cb275984 100644 --- a/project_templates/fastapi_safir_app/example/pyproject.toml +++ b/project_templates/fastapi_safir_app/example/pyproject.toml @@ -11,13 +11,13 @@ classifiers = [ "Development Status :: 4 - Beta", "Programming Language :: Python", "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.13", + "Programming Language :: Python :: 3.14", "Natural Language :: English", "Operating System :: POSIX", "Private :: Do Not Upload", "Typing :: Typed", ] -requires-python = ">=3.13" +requires-python = ">=3.14" dependencies = [ "fastapi>=0.100", "pydantic>2", @@ -32,7 +32,7 @@ Homepage = "https://example.lsst.io" Source = "https://github.com/lsst-sqre/example" [build-system] -requires = ["setuptools>=61", "wheel", "setuptools_scm[toml]>=6.2"] +requires = ["setuptools>=61", "setuptools_scm[toml]>=6.2"] build-backend = "setuptools.build_meta" [dependency-groups] diff --git a/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.github/workflows/ci.yaml b/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.github/workflows/ci.yaml index d23c8b2b..70cdbf02 100644 --- a/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.github/workflows/ci.yaml +++ b/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.github/workflows/ci.yaml @@ -4,7 +4,7 @@ env: # Current supported uv version. The uv documentation recommends pinning # this. The version should match the version used in .pre-commit-config.yaml # and frozen in uv.lock. It is updated by make update-deps. - UV_VERSION: "0.8.19" + UV_VERSION: "0.9.21" "on": merge_group: {} diff --git a/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.github/workflows/periodic-ci.yaml b/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.github/workflows/periodic-ci.yaml index b680657c..83291d7a 100644 --- a/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.github/workflows/periodic-ci.yaml +++ b/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.github/workflows/periodic-ci.yaml @@ -9,7 +9,7 @@ env: # Current supported uv version. The uv documentation recommends pinning # this. The version should match the version used in .pre-commit-config.yaml # and frozen in uv.lock. It is updated by make update-deps. - UV_VERSION: "0.8.19" + UV_VERSION: "0.9.21" "on": schedule: diff --git a/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.pre-commit-config.yaml b/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.pre-commit-config.yaml index 11b03b1a..2e09a239 100644 --- a/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.pre-commit-config.yaml +++ b/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.pre-commit-config.yaml @@ -7,13 +7,13 @@ repos: - id: trailing-whitespace - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.13.1 + rev: v0.14.10 hooks: - id: ruff-check args: [--fix, --exit-non-zero-on-fix] - id: ruff-format - repo: https://github.com/astral-sh/uv-pre-commit - rev: 0.8.19 + rev: 0.9.21 hooks: - id: uv-lock diff --git a/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.python-version b/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.python-version index 24ee5b1b..6324d401 100644 --- a/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.python-version +++ b/project_templates/fastapi_safir_app/{{cookiecutter.name}}/.python-version @@ -1 +1 @@ -3.13 +3.14 diff --git a/project_templates/fastapi_safir_app/{{cookiecutter.name}}/Dockerfile b/project_templates/fastapi_safir_app/{{cookiecutter.name}}/Dockerfile index 2002a191..3b7961b3 100644 --- a/project_templates/fastapi_safir_app/{{cookiecutter.name}}/Dockerfile +++ b/project_templates/fastapi_safir_app/{{cookiecutter.name}}/Dockerfile @@ -11,7 +11,7 @@ # - Runs a non-root user. # - Sets up the entrypoint and port. -FROM python:3.13.7-slim-trixie AS base-image +FROM python:3.14.2-slim-trixie AS base-image # Update system packages. COPY scripts/install-base-packages.sh . @@ -22,7 +22,7 @@ RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \ FROM base-image AS install-image # Install uv. -COPY --from=ghcr.io/astral-sh/uv:0.8.19 /uv /bin/uv +COPY --from=ghcr.io/astral-sh/uv:0.9.21 /uv /bin/uv # Install system packages only needed for building dependencies. COPY scripts/install-dependency-packages.sh . diff --git a/project_templates/fastapi_safir_app/{{cookiecutter.name}}/pyproject.toml b/project_templates/fastapi_safir_app/{{cookiecutter.name}}/pyproject.toml index 54a32282..58e7f425 100644 --- a/project_templates/fastapi_safir_app/{{cookiecutter.name}}/pyproject.toml +++ b/project_templates/fastapi_safir_app/{{cookiecutter.name}}/pyproject.toml @@ -11,13 +11,13 @@ classifiers = [ "Development Status :: 4 - Beta", "Programming Language :: Python", "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.13", + "Programming Language :: Python :: 3.14", "Natural Language :: English", "Operating System :: POSIX", "Private :: Do Not Upload", "Typing :: Typed", ] -requires-python = ">=3.13" +requires-python = ">=3.14" dependencies = [ "fastapi>=0.100", "pydantic>2", @@ -36,7 +36,7 @@ Homepage = "https://{{cookiecutter.name | lower}}.lsst.io" Source = "https://github.com/{{cookiecutter.github_org}}/{{cookiecutter.name}}" [build-system] -requires = ["setuptools>=61", "wheel", "setuptools_scm[toml]>=6.2"] +requires = ["setuptools>=61", "setuptools_scm[toml]>=6.2"] build-backend = "setuptools.build_meta" [dependency-groups] diff --git a/project_templates/technote_md/testn-000/technote.toml b/project_templates/technote_md/testn-000/technote.toml index e15bf561..84fa36a2 100644 --- a/project_templates/technote_md/testn-000/technote.toml +++ b/project_templates/technote_md/testn-000/technote.toml @@ -4,7 +4,7 @@ series_id = "TESTN" canonical_url = "https://testn-000.lsst.io" github_url = "https://github.com/lsst/testn-000" github_default_branch = "main" -date_created = 2026-01-05T22:18:41Z +date_created = 2026-01-05T22:26:49Z organization.name = "NSF-DOE Vera C. Rubin Observatory" organization.ror = "https://ror.org/048g3cy84" license.id = "CC-BY-4.0" diff --git a/project_templates/technote_rst/testn-000/technote.toml b/project_templates/technote_rst/testn-000/technote.toml index e96dad8c..3f6e80d2 100644 --- a/project_templates/technote_rst/testn-000/technote.toml +++ b/project_templates/technote_rst/testn-000/technote.toml @@ -4,7 +4,7 @@ series_id = "TESTN" canonical_url = "https://testn-000.lsst.io" github_url = "https://github.com/lsst/testn-000" github_default_branch = "main" -date_created = 2026-01-05T22:18:41Z +date_created = 2026-01-05T22:26:50Z organization.name = "NSF-DOE Vera C. Rubin Observatory" organization.ror = "https://ror.org/048g3cy84" license.id = "CC-BY-4.0"