feat!: adopt Python 3.15 and support BattlesnakeArena

- Require Python 3.15 in project metadata, runtime pin, and Docker stages.
- Use lazy imports for database backends and type-only dependencies.
- Defer benchmark dependencies until their code paths are used.
- Rely on deferred annotations and use Path.info for file discovery.
- Accept BattlesnakeArena alongside BattlesnakeEngine on game endpoints.
- Advance quart_common for Python 3.15 and multi-agent validation.
- Add pytest development dependencies and refresh the uv lockfile.
- Test lazy backend loading, import order, and fresh file discovery.
- Document the runtime requirements and locked uv workflow.

BREAKING CHANGE: Python 3.15 or newer is required; earlier runtimes cannot parse the lazy import syntax.
This commit is contained in:
2026-11-03 10:02:40 +01:00
parent f14d780f29
commit 5efab77248
35 changed files with 226 additions and 202 deletions
+2 -2
View File
@@ -1,5 +1,5 @@
# Stage 1 — compile sqlite-zstd + SQLite 3.49.1
FROM ghcr.io/astral-sh/uv:python3.13-trixie-slim AS sqlite-zstd-builder
FROM ghcr.io/astral-sh/uv:python3.15-trixie-slim AS sqlite-zstd-builder
RUN apt-get update && apt-get install -y --no-install-recommends \
curl unzip git libzstd-dev pkg-config build-essential ca-certificates && \
@@ -21,7 +21,7 @@ RUN git clone --depth=1 --branch v0.3.5 https://github.com/phiresky/sqlite-zstd.
cp target/release/libsqlite_zstd.so /usr/local/lib/libsqlite_zstd.so
# Stage 2 — runtime image
FROM ghcr.io/astral-sh/uv:python3.13-trixie-slim
FROM ghcr.io/astral-sh/uv:python3.15-trixie-slim
RUN apt-get update && apt-get install -y --no-install-recommends libzstd1 && \
rm -rf /var/lib/apt/lists/*