Python
The Python programming language through uv, with python, uv and uvx for running code and managing packages.
Usage
{
"features": {
"ghcr.io/hansehart/devcontainer-features/python:3": {}
}
}Version 3.2.0, see the changelog for what changed.
Options
| Option | Default | Description |
|---|---|---|
version | latest | Channel (latest), a minor line (major.minor), or an exact version (major.minor.patch). |
stateDir | If set, puts this feature's data at this path, which must be inside the remote user's home. Mount a volume there to persist it across rebuilds. | |
uvVersion | latest | uv channel (latest) or an exact version (major.minor.patch). |
Customizations
Open Secure Software Suite
The hosts the tool reaches:
| Host | Ports | Secret | For |
|---|---|---|---|
files.pythonhosted.org | 443 | Package downloads | |
pypi.org | 443 | Package index | |
releases.astral.sh | 443 | Python versions uv installs |
The variables that set its defaults:
| Variable | Value | For |
|---|---|---|
UV_CACHE_DIR | ${stateDir}/cache | uv's cache in the state dir |
UV_LINK_MODE | copy | With copy, environments hold copies of the cached packages |
UV_PYTHON_DOWNLOADS | manual | With manual, Python versions a project asks for install on explicit request |
UV_TOOL_BIN_DIR | ${stateDir}/bin | uv's tool commands in the state dir |
UV_TOOL_DIR | ${stateDir}/tools | uv's tools in the state dir |
VS Code
The extensions it installs: