Recently, people report that uv (https://docs.astral.sh/uv/) really makes a difference in Python tooling and puts poetry and of course anaconda unnessecary.
Poetry was arguably "necessary" in 2018, but pip's dependency resolver fundamentally changed in 2020.
The "vanilla" Python packaging toolchain has been gradually improving the whole time and people haven't given it much credit for that (largely because pip is still bad, and partly because they still resent that Setuptools is no longer interested in trying to be an all-in-one solution). Uv is largely possible (rather, as good as it is) because of that work (and because of the cooperation of uv project leadership with PyPA).
$ python3 -m venv .venv # Create a virtual environment
$ source .venv/bin/activate # Activate the virtual environment
(.venv) pip install <whatever you need> # Install stuff within the virtual environment
...
(.venv) deactivate
$ [sudo] rm -fR .venv
Can you not write shell scripts on Darwin?
> source .venv/bin/activate # Activate the virtual environment
This is a convenience, not a necessary step. All it does is manipulate a few environment variables. You can just specify the paths to the venv's pip and Python explicitly.
(Of course, you can script around the expectation of those environment variables, if you prefer that workflow.)
Also, pip 22.3 added the ability to install cross-environment, which allows for creating virtual environments much faster `--without-pip` (see e.g. https://zahlman.github.io/posts/2025/01/07/python-packaging-...).
> [sudo] rm -fR .venv
I can't fathom a reason you'd ever need sudo for this cleanup.
sudo pip install
If you are unexperienced, I recommend you stick with uv and set the env var: UV_MANAGED_PYTHON=trueThis will make uv not consider system python, only the uv-managed python versions. No more f-ing up the system python and juggling with multiple apt-installed python versions.
(Also, apt-installing multiple Python versions can already mess things up, from the reports I've seen. Building from source and installing it at a custom location that won't mess things up is easy, however.)
kgwxd•2mo ago
p4ul•2mo ago
[1] https://docs.astral.sh/uv/
r-johnv•2mo ago
VeejayRampay•2mo ago
kgwxd•2mo ago
zahlman•2mo ago
What exactly do you think is "ridiculous" about it? And what exactly do you believe it involves? Talk me through something you had to do that you think you shouldn't have had to do, or something you couldn't figure out how to do that you think should have been easy to do.