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
Compiling requirements.in files with file: requirements that are named, creates .txt output that lacks the names.
This is in contrast to urls which maintain names.
Thus disallowing .txt generated files from being used as constraints files.
Note: this worked in uv 0.1.2
Info
Version - uv 0.5.5 (95cd8b8b3 2024-11-27)
Platform - 24.1.0 Darwin
Arch - arm64
Example
# requirements.in
# normal requirement
mypy
# url req
nose @ git+https://github.com/salomon-smekecohen/nose@48735f874383f711c3b233ab1442cc9a26e96d6d
# file req
foo @ file:./something
# something/setup.py
from setuptools import setup
setup(name='foo', version='0.1')
# This file was autogenerated by uv via the following command:
# uv pip compile requirements.in -o requirements.txt
foo @ file:./something
# via -r requirements.in
mypy==1.13.0
# via -r requirements.in
mypy-extensions==1.0.0
# via mypy
nose @ git+https://github.com/salomon-smekecohen/nose@48735f874383f711c3b233ab1442cc9a26e96d6d
# via -r requirements.in
typing-extensions==4.12.2
# via mypy
Reality
# This file was autogenerated by uv via the following command:
# uv pip compile requirements.in -o requirements.txt
file:./something
# via -r requirements.in
mypy==1.13.0
# via -r requirements.in
mypy-extensions==1.0.0
# via mypy
nose @ git+https://github.com/salomon-smekecohen/nose@48735f874383f711c3b233ab1442cc9a26e96d6d
# via -r requirements.in
typing-extensions==4.12.2
# via mypy
The text was updated successfully, but these errors were encountered:
I thought pip didn't allow relative paths in file:, but I guess they do?
Yeah 😅. Vendoring this has just been an adventure all around. Excludingfile: in favor of just referencing the relative path produces the same results, but pip-tools outputs an absolute path to the .txt when you do that, so I use file: as a way to stay a bit more cross-compatible just in case other people read my requirements files and try to emulate anything without using uv.
Issue
Compiling requirements.in files with
file:
requirements that are named, creates.txt
output that lacks the names.This is in contrast to
url
s which maintain names.Thus disallowing
.txt
generated files from being used as constraints files.Note: this worked in uv 0.1.2
Info
Version -
uv 0.5.5 (95cd8b8b3 2024-11-27)
Platform -
24.1.0 Darwin
Arch -
arm64
Example
python -m uv pip compile requirements.in -o requirements.txt
Expectation
Reality
The text was updated successfully, but these errors were encountered: