Skip to content

Commit 22308c5

Browse files
committed
Add additional flags to uv pip install command
This commit adds the `--no-deps` and `--require-hashes` flags that had been omitted from the `uv pip install` command, and updates the corresponding comment. Rationale: - `--no-deps` ensures we only install the resolved dependency tree recorded in requirements.prod.txt (no additional dependency resolution). - `--require-hashes` enforces that every package has a hash entry in the requirements file, keeping installs deterministic Testing: - Ran `just clean`, `just prodenv`, and `just run-prod` locally.
1 parent c0daee2 commit 22308c5

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

justfile

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,10 @@ prodenv: requirements-prod
6565

6666
# --no-deps so that we only install the packages explicitly listed in requirements.prod.txt.
6767
# https://docs.astral.sh/uv/reference/cli/#uv-pip-install--no-deps
68-
uv pip install -r requirements.prod.txt
68+
#--require-hashes enforces that every package has a hash entry in
69+
# the requirements file, keeping installs deterministic
70+
# https://docs.astral.sh/uv/reference/cli/#uv-pip-install--require-hashes
71+
uv pip install --no-deps --require-hashes -r requirements.prod.txt
6972
touch $VIRTUAL_ENV/.prod
7073

7174

0 commit comments

Comments
 (0)