#14 [python_builder 6/9] RUN uv sync --locked --no-default-groups --no-install-project
#14 0.113 warning: `VIRTUAL_ENV=/opt/venv` does not match the project environment path `.venv` and will be ignored; use `--active` to target the active environment instead
will install the (unlocked) dependencies for the project.
Oversight in
uv#255uv syncdoes not respectVIRTUAL_ENVlike Poetry diduv add/uv sync/... do not respect the active virtualenv, should they? astral-sh/uv#6612 (comment)uv syncastral-sh/uv#5229In the case of
python-blueprintit ends up "working" becauseRUN uv build && \ pip install dist/*.whlwill install the (unlocked) dependencies for the project.
The recommended alternative from
uvisUV_PROJECT_ENVIRONMENTUV_PROJECT_ENVIRONMENTastral-sh/uv#6834Or the default
.venvcould be hard-coded.