Repository navigation
Description
Problem or Motivation
The image has Python 3.14 only (apt package python3.14, and python3 of sid is 3.14). The projects of the owner move to Python 3.15.2: homelab, infra, danielpetty.com and vibes declare requires-python = ">=3.15.2". In a container of the image, uv downloads a second CPython 3.15 into the home folder of each user, because the image has no Python that these projects accept.
Owner direction of 2026-11-26: the devtools image installs the tools, and PATH gives each user of the container the intended versions.
Debian sid has python3.15 3.15.2-1 for amd64 and arm64 (Debian archive, 2026-11-26).
Proposed Solution
Disposition: change the code.
- Add the apt package
python3.15to the apt step of theDockerfile.python3stays the default of sid, andpython3.14stays for the tool environments and for the consumers that name it. test/tools.shrunspython3.15 --version.- The Python tools of the image (copier, pre-commit, semgrep) stay on
/usr/bin/python3.14. Measured on 2026-11-26: the hashed lock of semgrep does not install on Python 3.15, becauseruamel-yaml-clib0.2.15 has no wheel for it. copier and pre-commit install.
Proof: the image builds on the two platforms, test/tools.Dockerfile passes, and in a container of the image uv sync of a project with requires-python = ">=3.15.2,<3.16" uses /usr/bin/python3.15 and downloads no Python.
Existing Tool Considered
apt of Debian sid, by the rule of the README: use apt where sid is current. sid has 3.15.2, which is the version that the projects require.
Proposed design
Problem statement
The image has only Python 3.14, and the default python3 of Debian sid is 3.14. The owner projects require Python 3.15.2, so uv downloads a second CPython 3.15 into the home folder of each user. The image must install /usr/bin/python3.15 from the Debian sid apt package, keep Python 3.14 and the default python3, and keep the Python tool environments on 3.14.
Acceptance criteria
Requirement: Install the python3.15 package
The apt step of the Dockerfile SHALL install the Debian sid package python3.15.
Scenario: Built image has Python 3.15
- WHEN The live check builds the image from the
Dockerfileand then buildstest/tools.Dockerfilewith--build-arg DEVTOOLSset to that image. - THEN The build passes and the
test/tools.shoutput shows+ python3.15 --versionfollowed by a line that starts withPython 3.15.2.
Requirement: Run python3.15 in the tool test
test/tools.sh SHALL run python3.15 --version through the run helper.
Scenario: Tool test runs the versioned interpreter
- WHEN The live check runs
test/tools.shin the built image with no network. - THEN The output contains the line
+ python3.15 --versionand the script exits 0.
Requirement: Keep Python 3.14 and the default python3
The image SHALL keep the apt package python3.14 and the Debian sid default python3.
Scenario: Built image keeps Python 3.14
- WHEN The live check runs
test/tools.shin the built image, which runsrun python --versionandrun python3.14 --version. - THEN Both commands exit 0 and each version line starts with
Python 3.14.
Requirement: Keep the tool environments on Python 3.14
The Python tool environments SHALL run on the /usr/bin/python3.14 interpreter.
Scenario: Tool environments report Python 3.14
- WHEN The live check runs
test/tools.shin the built image, which runs/usr/local/lib/devtools/copier/bin/python --version,/usr/local/lib/devtools/pre-commit/bin/python --versionand/usr/local/lib/devtools/semgrep/bin/python --version. - THEN Each command exits 0 and prints a version line that starts with
Python 3.14.
Requirement: Use the system Python 3.15 for uv sync
A project that declares requires-python = ">=3.15.2,<3.16" SHALL get the system Python 3.15 from uv sync in the image and SHALL download no Python.
Scenario: uv sync uses the system interpreter
- WHEN The live check runs
test/tools.shin the built image with no network, and the script runsUV_PYTHON_DOWNLOADS=never uv sync --no-cachein a temporary project withrequires-python = ">=3.15.2,<3.16"and no dependencies. - THEN
uv syncexits 0 anduv run python -c 'import sys; print(sys.base_prefix)'prints/usr.
Existing Tool Considered
No alternatives check has run. The open, maintained tool that covers the need is the Debian sid apt package python3.15 (3.15.2-1 for amd64 and arm64), from the apt step that already installs python3.14. It lacks a change of the default python3: it adds /usr/bin/python3.15 and leaves python3 on 3.14, so the image keeps python3.14 and python-is-python3. The change builds no tool of its own: it adds one package name to the apt list of the Dockerfile and the checks that prove it to test/tools.sh.
Key questions
- Should the image change the default
python3to Python 3.15?: No. The image keeps the Debian sid defaultpython3on 3.14 and adds/usr/bin/python3.15from the apt package. uv selects the versioned interpreter for a project that requires 3.15. (best practice) [sources: test/tools.sh:39, test/tools.sh:40]- Chosen: Keep the sid default python3 on 3.14.
python-is-python3and the tool environments keep the interpreter that they were built and tested with. The versioned/usr/bin/python3.15onPATHcovers the projects that require 3.15. - Rejected: Point python3 at /usr/bin/python3.15. It changes the default that sid and
python-is-python3set. It can break the packages and the tool environments that expect 3.14.
- Chosen: Keep the sid default python3 on 3.14.
- Which interpreter should the Python tool environments use?: Keep
/usr/bin/python3.14for copier, pre-commit and semgrep. The hashed lock of semgrep namesruamel-yaml-clib==0.2.15, which has no wheel for Python 3.15, so the hashed sync fails on 3.15. (best practice) [sources: python/semgrep.in:1, python/semgrep.txt]- Chosen: Keep all tool environments on Python 3.14. The 3.14 environments already install and run, the semgrep lock blocks 3.15, and one interpreter for all tool environments keeps the image consistent.
- Rejected: Move copier and pre-commit to 3.15 and keep semgrep on 3.14. It adds a second interpreter path and more test cases for no project need.
- Rejected: Move all tool environments to 3.15. The semgrep hashed lock fails on 3.15 because
ruamel-yaml-clib0.2.15 has no wheel for it.
- Should the image install Python 3.15 from apt or build it from source?: Install the Debian sid apt package
python3.153.15.2-1 for amd64 and arm64. The README rule takes apt where sid is current, and sid has the required 3.15.2. (best practice) [sources: README.md]- Chosen: Install the Debian sid apt package python3.15. sid has 3.15.2 for amd64 and arm64. apt gives the system interpreter at
/usr/bin/python3.15from the step that already installs Python 3.14. - Rejected: Build CPython 3.15 from source. It adds a compiler toolchain, build time and maintenance, and apt covers the need.
- Rejected: Use a uv-managed Python 3.15. It puts Python in a home folder and does not give the system interpreter that the issue needs.
- Rejected: Install Python 3.15 with mise. The README rule takes apt where sid is current. A mise Python is not the system interpreter and adds a second install path for Python.
- Chosen: Install the Debian sid apt package python3.15. sid has 3.15.2 for amd64 and arm64. apt gives the system interpreter at
- Does
test/manifests.shneed a change for Python 3.15?: No. The script runspython3to parsemise.toml, andpython3stays the sid default 3.14. [sources: test/manifests.sh:11] - How does uv select
/usr/bin/python3.15whenpython3stays 3.14?: uv searches the interpreters onPATHbefore it downloads one./usr/binis onPATH, and the apt package installs/usr/bin/python3.15with the version in its name, so uv picks it for a project that requires 3.15. The live check proves the choice withUV_PYTHON_DOWNLOADS=never, which makes a wrong selection fail instead of download a Python. (best practice) [sources: test/tools.Dockerfile]- Chosen: Rely on the uv PATH discovery and prove it with the live check.
/usr/binis onPATHand the versioned package installs/usr/bin/python3.15.UV_PYTHON_DOWNLOADS=neverin the live check makes a wrong selection fail the build. - Rejected: Pin UV_PYTHON=/usr/bin/python3.15 in the image ENV. It forces 3.15 on every project, including the projects and the tool environments that need 3.14.
- Rejected: Set UV_PYTHON_DOWNLOADS=never in the image ENV. It stops the download for every user, but a project that needs a Python the image lacks then fails. The issue asks for 3.15 on
PATH, not a change of the uv download policy for every consumer.
- Chosen: Rely on the uv PATH discovery and prove it with the live check.
Fit
Fits in one pull request.
Suspected block
None.
Dependencies
None.
Activity
dan-petty commentedon Nov 26, 2026
Both work on the devtools image, but #1 builds the image from debian:sid while this item adds one specific apt package to it.devops-cli-service commentedon Nov 26, 2026
Next step: the alternatives check records a verdict. See the section Proposed design of the body.
chore(main): release 1.3.0 (#96)
devops-cli-service commentedon Nov 26, 2026
Released in v1.3.0: https://github.com/dan-petty/devtools/releases/tag/v1.3.0