2 ms·
uv is purely a performance improvement, it changes nothing about the mechanics of Python environment management or packaging. The improvements came from lots o
by nickelpro 1y ago
uv is purely a performance improvement, it changes nothing about the mechanics of Python environment management or packaging.
The improvements came from lots of work from the entire python build system ecosystem and consensus building.
- 0cf8612b2e1e 1y agoDisagree in that uv makes switching out the underlying interpreter so straightforward. Becomes trivial to swap from say 3.11 to 3.12. The pybi idea. Sure, other tools could handle the situation, but being baked into the tooling makes it much easier to bootstrap different configurations.
- nickelpro 1y agoYes, it's faster and better than pyenv, but the mechanism it's using (virtual environments) is not a uv invention. uv does the Python ecosystem better than any other tool, but it's still the standard Python ecosystem as defined in the relevant PEPs.
- pityJuke 1y agoAre the lock files standardised, or a uv-specific thing?
- nickelpro 1y agouv has both a uv-specific implementation, and support for standard PEP 751 lockfiles
- collinmanderson 1y agoWorth noting uv-specific implementation has more features than that standard PEP 751 lockfiles, so uv plans to keep using its own implementation by default. https://github.com/astral-sh/uv/issues/12584 https://github.com/astral-sh/uv/issues/12584
- globular-toast 1y agoActually not true. One of the main differences with uv is you don't have to think about venvs any more. There's a talk about it from one of the authors at a recent PyCon here: https://www.youtube.com/watch?v=CV8KRvWKYDw https://www.youtube.com/watch?v=CV8KRvWKYDw (not the same talk I linked elsewhere in the thread).
- nickelpro 1y agoHow do you think uv works? It creates a venv. Note were talking about the concept of a virtual environment here, PEP 405, not the Python module "venv".
- lmm 1y agoThe implementation details don't matter. uv might follow PEP 405 but it could work just as well without doing so. The point is that it doesn't give you the bunch of extra footguns that any other Python package management does.
- nickelpro 1y agoIt matters immensely that it follows PEP 405, it makes uv the implementation detail. You can swap out uv for any other project management tool or build frontend and change nothing needs to change about the development environment. This is the entire purpose of the standards.
- lmm 1y ago> You can swap out uv for any other project management tool or build frontend and change nothing needs to change about the development environment. > This is the entire purpose of the standards. That seems to amount to saying that the purpose of the standards is to prevent progress and ensure that the mistakes of early Python project management tools are preserved forever. (Which would explain some things about the last ~25 years of Python project management I guess). The parts of uv that follow standards aren't the parts that people are excited about.