Packaging¶
packaging
¶
Centralized UV package management.
All Python package installations go through :func:uv_install.
No pip fallback — uv is required (the bootstrap downloads it).
Replaces all raw python -m pip install calls across the codebase.
UvNotFoundError
¶
Bases: RuntimeError
Raised when uv is not available on the system.
uv_install(python_exe, packages=None, *, index_url=None, requirements=None, upgrade=False, no_build_isolation=False, no_deps=False, editable=None, ignore_errors=False, timeout=600, log=None)
¶
Install Python packages via uv pip install.
Builds the full uv pip install command and delegates to
:func:~src.utils.commands.run_and_log.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
python_exe
|
Path
|
Path to the target venv Python executable.
Passed as |
required |
packages
|
list[str] | None
|
Package specifiers to install (e.g. |
None
|
index_url
|
str | None
|
PyPI index URL override ( |
None
|
requirements
|
Path | None
|
Path to a |
None
|
upgrade
|
bool
|
If |
False
|
no_build_isolation
|
bool
|
If |
False
|
no_deps
|
bool
|
If |
False
|
editable
|
Path | None
|
Path to install in editable mode ( |
None
|
ignore_errors
|
bool
|
Forwarded to :func: |
False
|
timeout
|
int
|
Command timeout in seconds. |
600
|
Returns:
| Type | Description |
|---|---|
CompletedProcess[str]
|
The completed process result. |
Raises:
| Type | Description |
|---|---|
UvNotFoundError
|
If |
CommandError
|
If the command fails and ignore_errors is False. |