Live data from Hacker News

uv downloads overtake Poetry for Wagtail users

wagtail.org

141–150 of 206 posts

Re: uv downloads overtake Poetry for Wagtail users

#141
post #18

For the uninitiated what is the benefit of UV over pip? I've been working with pip for so long now that I barely notice it unless something goes very wrong.

- uv is aware of your dependencies, you can add/remove development dependencies, create group of development dependencies (test, lint, dev, etc) and add or remove those and only those at will. You can add dependencies and optional dependencies for a project as well, think my_app[cli,standard]. You don't need to have different requirements.txt for each case nor do you need to remove things by hand as you'd do in pip,…

...

- uv tool replaces pipx etc.

- uv pip --tree replaces pipdeptree (including 'inverse' mode)

- ...

Re: uv downloads overtake Poetry for Wagtail users

#142
post #9

Not a surprise. I said it before and I'll say it again, all the competing projects should just shut up shop for the good of Python. uv is so much better it's like pushing penny farthings after the safety bike has been invented.

That's rough for all the creators of poetry, pdm, pipenv, etc. to hear. They put in a ton of great work over the last decade, but I fear you may be right.

Oh yeah, pipenv which was a shoddy mess that used personal connections and reputation to get promoted on the python website and poetry where the developer did a good job dismissing requests to support common use cases (like overriding dependencies).

Re: uv downloads overtake Poetry for Wagtail users

#143
post #72
post #63

Earlier quoted context omitted.

IMO if you require libraries in other languages then a pure python package manager like uv, pip, poetry, whatever, is simply the wrong tool for the job. There is _some_ support for this through wheels, and I'd expect uv to support them just as much as pip does, but they feel like a hack to me. Instead there is pixi, which is similar in concept to uv but for the conda-forge packaging ecosystem. Nix and guix are also l…

But for example, if I install the Python package "shapely", it will need a C package named GEOS as a shared library. How do I ensure that the version of GEOS on my system is the one shapely wants? By trial and error? And how does that work with environments, where I have different versions of packages in different places? It sounds a bit messy to me, compared to a solution where everything is managed by a single pack…

This type of situation is why I use Docker for pretty much all of my projects—single package managers are frequently not enough to bootstrap an entire project, and it’s really nice to have a central record of how everything needed was actually installed. It’s so much easier to deal with getting things running on different machines, or things on a single machine that have conflicting dependencies.

Re: uv downloads overtake Poetry for Wagtail users

#144

I recently checked out UV, and it's impressively fast. However, one challenge that keeps coming up is handling anything related to CUDA and Torch. Last week, I started developing directly in PyTorch containers using just pip and Docker. With GPU forwarding on Windows no longer being such a hassle, I'm really enjoying the setup. Still, I can’t shake the feeling that I might be overlooking something critical. I’d love…

At least my kind of problems were solved by

https://docs.astral.sh/uv/guides/integration/pytorch/#instal...

Re: uv downloads overtake Poetry for Wagtail users

#145

I recently checked out UV, and it's impressively fast. However, one challenge that keeps coming up is handling anything related to CUDA and Torch. Last week, I started developing directly in PyTorch containers using just pip and Docker. With GPU forwarding on Windows no longer being such a hassle, I'm really enjoying the setup. Still, I can’t shake the feeling that I might be overlooking something critical. I’d love…

I assume you've seen this:

https://docs.astral.sh/uv/guides/integration/pytorch/

If the platform (OS) solution works for you that's probably the easiest. It doesn't for me because I work on multiple Linux boxes with differing GPUs/CUDAs. So I've use the optional dependencies solution and it's mostly workable but with an annoyance that uv sync forgets the --extra that have been applied in the venv so that if you "uv add" something it will uninstall the installed torch and install the wrong one until I re-run uv sync with the correct --extra again. (uv add with --extra does something different) And honestly I appreciate not having hidden venv states but it is a bit grating.

There are some ways to setup machine/user specific overrides with machine and user uv.toml configuration files.

https://docs.astral.sh/uv/configuration/files/

That feels like it might help but I haven't figured out how to configure get that to help it pick/hint the correct torch flavor for each machine. Similar issues with paddlepaddle.

Honestly I just want an extras.lock at this point but that feels like too much of a hack for uv maintainers to support.

I have been pondering whether nesting uv projects might help so that I don't actually build venvs of the main code directly and the wrapper depends specifically on certain extras of the wrapped projects. But I haven't looked into this yet. I'll try that after giving up on uv.toml attempts.

Re: uv downloads overtake Poetry for Wagtail users

#146
post #4

Earlier quoted context omitted.

It's the integrated python version management which sold me. Took a huge chunk of complexity out of bootstrapping projects which I was otherwise handling myself.

This is the one thing that took a while for me to get to grips with. I tend to use `asdf` for my python version management, which I want to continue to use since I use it for most other languages. It'd be nice if we could have a shim for `uv` that allows it to play nice with `asdf` (there is an `asdf-uv` but seems to be about installing different versions of `uv` when instead I want to install different versions of p…

The tool mise-en-place seems to have this. It is a replacement for asdf that I think can be used as a drop in replacement (compatible CLI interface).

Re: uv downloads overtake Poetry for Wagtail users

#147

Earlier quoted context omitted.

This is the one thing that took a while for me to get to grips with. I tend to use `asdf` for my python version management, which I want to continue to use since I use it for most other languages. It'd be nice if we could have a shim for `uv` that allows it to play nice with `asdf` (there is an `asdf-uv` but seems to be about installing different versions of `uv` when instead I want to install different versions of p…

The tool mise-en-place seems to have this. It is a replacement for asdf that I think can be used as a drop in replacement (compatible CLI interface).

Yes you can sync versions python versions bidirectionally with uv and mise. I intend to make further deeper integrations with uv where possible directly into mise core in order to offload python complexity out of mise and into uv where possible.

Re: uv downloads overtake Poetry for Wagtail users

#148
post #141

Earlier quoted context omitted.

- uv is aware of your dependencies, you can add/remove development dependencies, create group of development dependencies (test, lint, dev, etc) and add or remove those and only those at will. You can add dependencies and optional dependencies for a project as well, think my_app[cli,standard]. You don't need to have different requirements.txt for each case nor do you need to remove things by hand as you'd do in pip,…

... - uv tool replaces pipx etc. - uv pip --tree replaces pipdeptree (including 'inverse' mode) - ...

indeed, thanks! it does so much for a tool that's like a year old, crazy stuff.

Re: uv downloads overtake Poetry for Wagtail users

#149
I just taught a week long course, Advanced Python for Data Scientists. The first day we discussed how to use uv. The feedback was "this UV content is worth the price of the whole course".

Using uv is an easy sell to anyone who has worked with Python.

Great work Charlie and team.

Re: uv downloads overtake Poetry for Wagtail users

#150
post #53

Earlier quoted context omitted.

That's rough for all the creators of poetry, pdm, pipenv, etc. to hear. They put in a ton of great work over the last decade, but I fear you may be right.

I quite really like pdm! I can see why maybe poetry but especially pipenv might be replaced with uv, but what's the value of uv over pdm beyond performance? It ticks all my boxes otherwise.

>but what's the value of uv over pdm beyond performance

uv is not written in python so it doesn't suffer from the bootstrap problem of having a python version installed to begin using it. Users (new and even experienced) get confused and annoyed when they try to use python tooling in the same venv as their application instead of using pipx.

People also get confused and annoyed if they use mac and run `brew upgrade` and find themselves with python 3.13 or just any version that is new (yes we can pin to python@3.11 or whatever) so pyenv is a good option.

So now you have pdm, pipx, and pyenv to manage all this stuff. With uv all this hassle goes away.

Post reply on HN