Live data from Hacker News

Conda: A package management disaster?

pyherald.com

121–130 of 234 posts

Re: Conda: A package management disaster?

#121

Earlier quoted context omitted.

The answer is not Yet Another Tool In The Chain. Python community itself needs to address this. Because if they don’t then you’ll have requirements.txt, setuptools, pyproject, pip, pipx, pipenv, pyenv, venv, nix.

The thing is, Nix is not Yet Another Tool, it is the tool.

And so was Docker before Nix

Re: Conda: A package management disaster?

#122

It's rare to see something as systematically broken as Python package/dependencies ecosystem. What I don't understand - what makes this so difficult to solve in Python? It seems that many other platforms solved this a long time ago - maven 2.0 was released almost 20 years ago. While it wasn't / isn't by no means perfect, its fundamentals were decent already back then. One thing which I think messed this up from the b…

> what makes this so difficult to solve in Python? Python creates the perfect storm for package management hell: - Most the valuable libraries are natively compiled (so you get all the fun of distributing binaries for every platform without any of the traditional benefits of native compilation) - The dynamic nature makes it challenging to understand the non-local impacts of changes without a full integration test sui…

> Too many fractured packaging solutions, not a single one well designed. And they all conflict.

100% this.

Last 4 years, one of the most frustrating parts of SWE that I need to deal with on a daily basis is packaging data science & machine learning applications and APIs in Python.

Maybe this is a very mid-solution, but one solution that I found was to use dockerized local environments with all dependencies pinned via Poetry [1]. The start setup is not easy, but now using some other Make file, it's something that I take only 4 hours with a DS to explain and run together and save tons of hours of in debugging and dependency conflict.

> Python developers would rather save 1 line of code in the moment, even if it pushes the complexity off to another part of the system.

Sounds odd to me in several projects that I worked on that folks bring the entire dependency on Scikit-Learn due to the train_test_split function [2] because the team thought that it would be simpler and easier to write a function that splits the dataset.

[1] - https://github.com/orgs/python-poetry/discussions/1879 [2] - https://scikit-learn.org/1.5/modules/generated/sklearn.model...

Re: Conda: A package management disaster?

#124
post #76

Earlier quoted context omitted.

Poetry is pretty slow. I think `uv` will ultimately displace it on that basis alone.

Can you recommend any good article / comparison of uv vs poetry vs conda? We've used different combinations of pipx+lockfiles or poetry, which has been so far OK'ish. But recently discovered uv and are wondering about existing experience so far across the industry.

From my experience, uv is way better and it's also PEP compliant in terms of pyproject.toml. Which means in cas uv isn't a big player in the future, migrating away isn't too difficult.

At the same time, poetry still uses a custom format and is pretty slow.

Re: Conda: A package management disaster?

#125

It's rare to see something as systematically broken as Python package/dependencies ecosystem. What I don't understand - what makes this so difficult to solve in Python? It seems that many other platforms solved this a long time ago - maven 2.0 was released almost 20 years ago. While it wasn't / isn't by no means perfect, its fundamentals were decent already back then. One thing which I think messed this up from the b…

Agreed. But the problem is now fully solved by https://docs.astral.sh/uv/.

Re: Conda: A package management disaster?

#126

It's rare to see something as systematically broken as Python package/dependencies ecosystem. What I don't understand - what makes this so difficult to solve in Python? It seems that many other platforms solved this a long time ago - maven 2.0 was released almost 20 years ago. While it wasn't / isn't by no means perfect, its fundamentals were decent already back then. One thing which I think messed this up from the b…

Agreed. But the problem is now fully solved by https://docs.astral.sh/uv/ .

easy if you start from scratch, hard if you want to get existing projects working

also it doesn't always work, I got stuck with some dependencies when it works it's amazing

Re: Conda: A package management disaster?

#127

The problem conda solved that nothing had solved before was installing binary dependencies on MS Windows. Before conda, getting a usable scipy install up and running on MS Windows was a harrowing experience. And having two independent installations was basically impossible. The real hard work that went into conda was reverse engineering all the nooks and crannies of the DLL loading heuristics, to allow it to ensure t…

This was mostly because most scientific packages didn't provide Windows binary builds for many years.

Today you can just "pip install scipy" on Windows at it will just work.

Re: Conda: A package management disaster?

#128

It's rare to see something as systematically broken as Python package/dependencies ecosystem. What I don't understand - what makes this so difficult to solve in Python? It seems that many other platforms solved this a long time ago - maven 2.0 was released almost 20 years ago. While it wasn't / isn't by no means perfect, its fundamentals were decent already back then. One thing which I think messed this up from the b…

It is not a new discovery that Python is terrible for packaging and distribution. Unfortunately, very little has been done about this. The fact that Python is used on particular environments controlled by the developers, mainly machine learning, makes this even more difficult to fix.

It's not really true to say "very little has been done." Thousands of person-hours have been invested into this problem! But the results have been mixed.

At least uv is nice! https://docs.astral.sh/uv/

Re: Conda: A package management disaster?

#129
post #111
post #63

Earlier quoted context omitted.

I think at least part of it is that there are so many solutions for Python packaging, which are often intermixed or only half-supported by developers. It's a tough ask to provide dedicated support for pip, conda, poetry and what else is there plus a couple different ways to create virtual environments. Of course if you do everything right, you set it up once (if even that) and it just keeps working forever, but it is…

The problem is a lot of Python source is actually a C/C++ file, so simply having "source based package manager for Python" is very annoying, as you'd have to manage your C/C++ sources with some other mechanisms. This is exactly the reason I've moved from pip to conda for some projects: "pip" was acting a source-based package manager, and thus asking for C tools, libraries and dev headers to be installed - but not pro…

This used to be a big headache for me, especially having developers on Windows but deployment targets in Linux, but a lot of the libraries I commonly use these days are either pure python or ship wheels for the platforms I use.

Were your issues recent or from several years ago?

Re: Conda: A package management disaster?

#130
I tried Conda a number of time over the years, regretted it every time.

These days, when I absolutely have to use it because some obscure piece of software can't run unless Conda, I install it in a VM so that:

    - I protect my working system from the damage of installing Conda on it

    - I can throw the whole garbage fire away without long term brain damage to my system once I'm done
Post reply on HN