Live data from Hacker News

uv downloads overtake Poetry for Wagtail users

wagtail.org

171–180 of 206 posts

Re: uv downloads overtake Poetry for Wagtail users

#171
post #81

I keep reading praise about uv, and every single time I never really understand what problems it addresses. I've got a couple quite big Django projects for which I've used venv for years, and not once have I had any significant issues with it. Speed at times could have been better and I would have liked to have a full dependency list lock file, but that never caused me issues. The only thing that comes to mind is tho…

I'm in the same boat. Sure it's nice and better, but I haven't felt so much annoyance with the python ecosystem that I desperately need something better. I use VS Code and it takes care of venv automatically, so I am biased by that.

Re: uv downloads overtake Poetry for Wagtail users

#172
post #157

uv, ruff.... Astral doesn't miss. Excited to see what else they can bring to the Python world. Had an issue running something on the latest Python version installed (3.13) but only needed to 'downgrade' to 3.11 to run that particular script. Just a simple: `uv run --python 3.11 --with openai-whisper transcribe.py` And no need to mess with anything else.

> what else they can bring

type checking

Re: uv downloads overtake Poetry for Wagtail users

#174
post #97

Earlier quoted context omitted.

I’m a bit confused why uv is not an option for you. You don’t need to compile Python, it manages virtualenvs for you, you can use them with Jupyter and vscode. What are you missing?

So the only difference is that Conda also isolates "system" libraries (like libcublasLt.so), or does uv also do this? It's not that uv is not an option for me, I made this move to miniforge before uv was on my radar because it wasn't popular, but I'm still at a point where I'm not sure if uv can do what I need.

Try Pixi (https://prefix.dev/). It uses uv for Python while also managing your other libraries from Conda. It has a migration path from Conda.

Re: uv downloads overtake Poetry for Wagtail users

#175
post #48
post #30

Earlier quoted context omitted.

You do not need a damn good reason for this. Just try it out on a simple hello world. Then try it out on a project already using poetry for eg. uv init uv sync and you're done I'd say if you do not run into the pitfalls of a large python codebase with hundreds of dependencies, you'll not get the bigger argument people are talking about.

I don't think you need to sync, do you? It always just does it when running. That said, I do wish uv had `uv activate`. I like just working in the virtualenv without having to `uv run` everything.

I keep going back and forth on ‘uv run’. I like being explicit with the tooling, but it feels like extra unneeded verbosity when you could just interact with the venv directly. Especially since I ported a bunch of scripts from ‘poetry run’

Re: uv downloads overtake Poetry for Wagtail users

#176
post #119
post #91

Earlier quoted context omitted.

Indeed, I'd want something where I have more control over how the binaries are built. I had some segfaults with conda in the past, and couldn't find where the problem was until I rebuilt everything from scratch manually and the problems went away. Nix/guix sound interesting. But one of my systems is an nVidia Jetson system, where I'm tied to the system's libc version (because of CUDA libraries etc.) and so building t…

with uv (and pip) you can pass the --no-binary flag and it will download the source code and build all you dependencies, rather than downloading prebuilt binaries. It should also respect any CFLAGS and LDFLAGS you set, but I haven't actually tested that with uv.

I just tried --no-binary with the torchvision package (on a Jetson system). It failed. Then I downloaded the source and it compiled without problems.

Re: uv downloads overtake Poetry for Wagtail users

#177
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.

They served their purpose for the decade, so they can be happy that they did their thing to pave the road for a good successor. uv some day will also find it successor, this is how software lives. Celebrate the life, don't cry for how it ends.

Re: uv downloads overtake Poetry for Wagtail users

#178
post #165

As an aside, I can't praise the Wagtail CMS highly enough. It sets a high bar for usability and accessibility of the auto-generated content management UI. The developer experience is top notch with excellent documentation and many common concerns already handled by Wagtail or Django. A significant amount of Wagtail-specific code is declarative, essentially describing data model, relationships, and UI fields. The part…

ty! We have no plans to rewrite Wagtail in Rust but I hope there’s ways in which we can make the developer experience better, particularly around dependencies management

Re: uv downloads overtake Poetry for Wagtail users

#179

Earlier quoted context omitted.

You can still `source .venv/bin/activate(.fish)` and skip the uv run bit. I have Fish shell configured to automatically activate a .venv if it finds one in a directory I switch to.

I do do that, can you please share your fish script to autoload it? I have something for Poetry envs, but not venv dirs.

Sure thing - so I mostly ended up using this for activating a .venv in a fabfile directory using this...

    function __auto_fab --on-variable PWD
        iterm2_print_user_vars
        if [ -d "fabfile" ]
            if [ -d "fabfile/.venv" ]
                if not set -q done_fab
                    and not set -q VIRTUAL_ENV
                    echo -n "Starting fabfile venv... "
                    pushd fabfile > /dev/null
                    source .venv/bin/activate.fish  --prompt="[fab]"
                    popd > /dev/null
                    set -g done_fab 1
                    echo -e "\r Fabfile venv activated         "
                end
            else
                echo "Run gofab to create the .venv"
            end
        end
    end

I've since deleted the one to do a .venv in this directory, but I think it was roughly this...

    function __auto_venv --on-variable PWD
        if [ -d ".venv" ]
            if not set -q done_venv
                echo -n "Starting venv... "
                source .venv/bin/activate.fish  --prompt="[venv]"
                set -g done_venv 1
                echo -e "\r Venv activated         "
            end
        end
    end

(just tested that and it seems to work - the --prompt actually gets overridden by the project name from uv's pyproject.toml now though so that's not really necessary, was useful at some point in the past)

These live in ~/.config/fish/conf.d/events.fish

Re: uv downloads overtake Poetry for Wagtail users

#180

Earlier quoted context omitted.

I do do that, can you please share your fish script to autoload it? I have something for Poetry envs, but not venv dirs.

Sure thing - so I mostly ended up using this for activating a .venv in a fabfile directory using this... function __auto_fab --on-variable PWD iterm2_print_user_vars if [ -d "fabfile" ] if [ -d "fabfile/.venv" ] if not set -q done_fab and not set -q VIRTUAL_ENV echo -n "Starting fabfile venv... " pushd fabfile > /dev/null source .venv/bin/activate.fish --prompt="[fab]" popd > /dev/null set -g done_fab 1 echo -e "\r F…

Thank you!
Post reply on HN