You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my project i have a pyproject.toml which contains my dependencies and maps my lib directory as a local package.
When i run pip install . it installs my dependencies and my lib directory as my project name (my-project for example) and version specified in my pyproject.toml (version is actually dynamic).
In order to have uv pip compile also include my local package, i needed to create a requirements.in which contains only . (i have a separate one for requirements-dev.in containing -e .[dev] for additional development dependencies).
When I run uv pip compile requirements.in -o requirements.txt, it generates the file as expected except for the line; my-project @ .
When I run uv pip compile requirements-dev.in -o requirements-dev.txt, it generates the file as expected except for the line; -e .
Now, when I run vanilla pip install -r requirements-dev.txt it works as expected, but when I run pip install -r requirements.txt, it complains that the line my-project @ . is not valid. This works fine however when running uv pip install -r requirements.txt but my goal is to not have a hard dependency on uv when installing already pinned versions like this. Is it possible to accomplish this?
The text was updated successfully, but these errors were encountered:
Nomelas
changed the title
pip compile with local disk package?
pip compile with local disk package without hard dependency on uv?
May 14, 2024
Yes, pip does not support relative paths with named dependencies, and we always output with names. You can track and chime in here if you'd like: #3180
This is my situation,
In my project i have a
pyproject.toml
which contains my dependencies and maps mylib
directory as a local package.When i run
pip install .
it installs my dependencies and my lib directory as my project name (my-project for example) and version specified in mypyproject.toml
(version is actually dynamic).In order to have
uv pip compile
also include my local package, i needed to create a requirements.in which contains only.
(i have a separate one for requirements-dev.in containing-e .[dev]
for additional development dependencies).When I run
uv pip compile requirements.in -o requirements.txt
, it generates the file as expected except for the line;my-project @ .
When I run
uv pip compile requirements-dev.in -o requirements-dev.txt
, it generates the file as expected except for the line;-e .
Now, when I run vanilla
pip install -r requirements-dev.txt
it works as expected, but when I runpip install -r requirements.txt
, it complains that the linemy-project @ .
is not valid. This works fine however when runninguv pip install -r requirements.txt
but my goal is to not have a hard dependency on uv when installing already pinned versions like this. Is it possible to accomplish this?The text was updated successfully, but these errors were encountered: