-
Notifications
You must be signed in to change notification settings - Fork 2.9k
UV_COMPILE_BYTECODE=1 please? 🥺 #6493
Copy link
Copy link
Closed
Labels
Description
Hello, it is I again, your obnoxious Docker user!
As the documentation correctly states, bytecode-compilation is super useful in Docker containers. Could we have a UV_COMPILE_BYTECODE=1 to set once and forget?
If one only uses it to install one app, it's no big deal to also pass --compile-bytecode, but thanks to uv tool, I've got the following block in my build container:
ENV PATH=/root/.local/bin:/root/.cargo/bin:$PATH \
UV_INDEX_URL=$PIP_INDEX_URL \
UV_LINK_MODE=copy \
UV_PYTHON_DOWNLOADS=never \
UV_PYTHON=/usr/bin/python3.12
RUN --mount=type=cache,target=/root/.cache \
set -ex \
&& uv tool install --compile-bytecode secret-internal-tool \
&& uv tool install --compile-bytecode pdm \
&& uv tool install --compile-bytecode hatch \
&& uv tool install --compile-bytecode virtualenv \
&& ...It would be great if I could just move it to the ENVs.
Reactions are currently unavailable