4 ms·
> With x, packaging in Python is a solved problem This is the claim that has been made about every "advancement" in python packaging for the last 20 years. Som
by ris 6y ago
> With x, packaging in Python is a solved problem
This is the claim that has been made about every "advancement" in python packaging for the last 20 years. Some of us have been kicking around long enough to remember the great saviour being distutils, setuptools, easy_install, eggs, wheels, pip, pipfiles/pip-tools... The truth being that all people have managed to do is produce a horrific mess with an ever growing tower of components each of which never really solves the problem (and now people want me to add "tox" to the mix too!). I have to say that packaging is really the worst part of the python world.
I do my best these days to avoid every component of the python packaging ecosystem I possibly can and use Nix as much as possible, which really Just Solves The Problem.
- drcongo 6y agoI agree that packaging is horrible in Python. Poetry is mostly excellent, but I have one project where running `poetry lock` takes over an hour and I have no idea why. I keep seeing this claim about Nix, and I keep trying to understand it, but every time I look into it I come out more confused. Nix appears to be an operating system (?) and packaging things _for_ Nix seems to be something akin to a dockerfile, but one that will only work on a machine with the Nix operating system? If I've got all of that right (which is a big "if"), I can see how that's useful for building a system's dependencies and deploying it to a Nix OS server, but I can never work out how any of it is useful if I don't run Nix OS on the servers or I want to distribute a Python package.
- ris 6y agoSo... Nix is just a package manager, but it's a package manager that tries to be as generic as possible and only have the attitude that a "package" is just "a bunch of (immutable) files that depend on the presence of another bunch of files" and so should be able to take over the job of all package mangers on your system (no matter how much of a special snowflake language x or application y thinks it is and deserves its own, inevitably crappy, package manager). One of the many advantages this brings is that your system's software installation makes sense "as a whole" and isn't the result of 7 different package managers or "auto updating" applications fighting each other. But because of this, Nix can only have things depend on packages it has provided itself. It doesn't assume anything about the host system apart from the kernel. So yes, installing Nix on an existing Linux system can feel like installing another distribution. But you only ever have to use as much of it as you want to. Everything lives in /nix, and to get rid of everything you just have to `rm -rf /nix`. NixOS is a full distribution that just uses Nix for everything, including configuration management.