News for hackers. Stuff that matters.
Re:Uv's killer feature is pulling in local dependencies by selcuka on Sunday January 12, 2025 @06:09PM (#42677959)
With pip the best practice is to have a requirements.txt with direct requirements (strictly or loosely pinned), and a separate constraints.txt file [1] with strictly pinned versions of all direct- and sub-dependencies (basically the output of `pip freeze`). The latter works like a lock file.

[1] https://pip.pypa.io/en/stable/user_guide/#constraints-files

Re:Uv's killer feature is pulling in local dependencies by zahlman on Monday January 13, 2025 @12:57AM (#42680493)
For direct requirements you're better off using the `pyproject.toml` for direct dependencies (and you can plausibly use it to pin everything if you're developing an application). It's project metadata that you'll need anyway for building your project, and the "editable wheel" hack allows Pip to use that information to set up an environment for your code (via `pip install -e .`).