Live data from Hacker News

Why We're Moving on from Nix

blog.railway.com

131–140 of 144 posts

Re: Why We're Moving on from Nix

#131
post #126

Earlier quoted context omitted.

> It’s so exhausting that every single time a basic use issue comes up with nix, the response is “but there’s a way to work around it (that you need tribal knowledge for and will require writing dozens to hundreds of lines of code to fix in a language that doesn’t work like any of the mainstreams with bad error messages and poorly documented standard libraries)”. > People’s problems with nix are not that it isn’t tur…

I’m very sorry. But for a person that tries to get into Nix this reads like pure gaslighting. I haven’t even found an official description of what Nix vs NixOS vs nixpkgs tries to achieve vs what they do not want to achieve. There is a near infinite collection of blog posts what people use Nix for. All full of Nix-internal jargon derisively critiquing alternative (that do in fact actually work) without ever coming ou…

A lot of work about packaging specifics reads like inside baseball because it is. Most people manage to avoid getting into the specifics of packaging because it’s stuff that mostly gets in the way of the problem they’re trying to solve. But for blessed few packaging is either critical to the problem or is the problem itself. If you never had to learn the inside baseball terminology, it is likely that packaging is not critical to problems that you solve, and I say that without judgment. If you need to get into Nix, you will. There are lots of reasonable ways to manage personal infrastructure that don’t involve Nix. For the problem you describe, I’m not even sure Nix is a preferable solution unless you already use it.

That said, I agree with the original comment. I’m willing to believe that they had these problems and that moving away from Nix was the right decision, but there is little detail in the explanation. They’ve been pretty closed users of Nix to my knowledge, building proprietary tools on top of it without contributing back significantly, and it feels like orgs such as repl.it are contributing back more actively, but this may be a marketing difference as well.

Re: Why We're Moving on from Nix

#132
post #112
post #84

Earlier quoted context omitted.

I often find it takes about 10 minutes of my time to package your average python package into nix, or 1 minute if its pyproject.toml based (uv/poetry projects!. There is a long tail though ( cough weasyprint cough ).

That's mostly just a tooling issue/a paradigm mismatch. Python's package management is notoriously bad, so it sorta makes sense that it won't fit as nicely with Nix.

"just a tooling issue/a paradigm mismatch" is how many people pronounce "bad UX".

Re: Why We're Moving on from Nix

#133
post #126

Earlier quoted context omitted.

> It’s so exhausting that every single time a basic use issue comes up with nix, the response is “but there’s a way to work around it (that you need tribal knowledge for and will require writing dozens to hundreds of lines of code to fix in a language that doesn’t work like any of the mainstreams with bad error messages and poorly documented standard libraries)”. > People’s problems with nix are not that it isn’t tur…

I’m very sorry. But for a person that tries to get into Nix this reads like pure gaslighting. I haven’t even found an official description of what Nix vs NixOS vs nixpkgs tries to achieve vs what they do not want to achieve. There is a near infinite collection of blog posts what people use Nix for. All full of Nix-internal jargon derisively critiquing alternative (that do in fact actually work) without ever coming ou…

I think you may be overthinking things. In brief;

Nix is two things: a functional programming language called Nix, and a package manager written in C++ that compiles and installs packages written with Nix expressions. Nix the language itself, and it's implementation.

Nixpkgs is a repository of Nix packages. It also contains NixOS, which is also just a bunch of Nix.

NixOS is a Linux-based operating system built on Nix. It is configured using NixOS modules, a configuration system of sorts built on top of the Nix programming language. A NixOS system is literally a single big Nix package built from NixOS modules that depends on a bunch of other packages.

If this still seems too complicated it would probably be better to just dive in and mess with it so you can physically see what's going on.

> current problem is taking a homelab server into “production” and all I really want is a way to write down a state I want the services on it to be in, have that in a git repo and be able to regenerate this server after loosing it (in a first step without any data backup). I’m still, after 2 months (wall clock, call it maybe 3 days actually getting into this project), not sure if that’s a thing Nix tries to cover! (I think it does, but..)

Yes that does sound like something NixOS can cover. Obviously, you will still need backups for your mutable data (databases, files, etc.), but if you are able to encapsulate the entire setup of a server into a NixOS config you can indeed throw a machine out the window and have a new one set up and booting the exact same services in minutes.

This is pretty much the original thing that drew me into NixOS, especially because at the time I was highly interested in qemu GPU passthrough setups and I really liked how with Nix all of the complicated setup bits could be expressed in a single file, with about 20 lines of Nix, all accounted for and version controlled. A lot better than just hoping you remember to keep things documented.

I won't lie, learning NixOS and using it for a real machine setup was very painful for me at first. I struggled with many things over time. Still, I really think because the scope of things these projects do is huge it's really easy to overcomplicate things. All of the explosive scope of Nix comes from relatively simple primitives applied in large systems.

I really don't want to encourage people to suffer with Nix if they feel like it's just too convoluted and hard to work with. I am not trying to convey that Nix is simple or easy on the whole. I was only ever trying to explain why I felt the issues raised by this post were confusing to me, not trying to tell people that Nix is generally easy. I think a lot of replies genuinely continue to misunderstand this, but the point of saying that it's easy to do that in Nixpkgs is not to dunk on people who struggle with Nix, it's to say that it's not clear why Nixpacks would struggle with these particular issues. You can literally just split the /nix/store paths into separate OCI layers. There is no obvious reason why this strategy can't be used, and the blog post doesn't go into the background behind it. I bet there actually is background, it's just left unsaid.

Re: Why We're Moving on from Nix

#134

Earlier quoted context omitted.

Yea, i kinda hate Nix - but it's fundamentally changed how i view OSs and the minimum features i want from them. Though I really want another language than Nixlang, but i've been stuck on Nix for years despite not liking it because the concrete builds are just so good. If Nix actually had a language i liked i'd probably go full immutable user config too and fully embrace nix. It's just so, so good. I'd switch in a he…

If you like Lisp there is GUIX which is the Nix packaging idea but using a language that is slightly less trash. The ecosystem is much worse so it would not be great for a desktop end user AFAIK.

I'm hoping Nickel some day can be used in place of Nix. I'm not a fan of lazy piles of config-func-soup regardless, but if i just had types and sane errors my UX in Nix would go up tremendously. Nickel promises some of that, at least.

Re: Why We're Moving on from Nix

#135

Earlier quoted context omitted.

> The industry is full of ineptitude though. While I disagree with the person you're replying to, I find your reply dismissive. I don't know the behind-the-scnene reasons for this, but I can very very easily apply a very similar situation to this from my experience. Nix is a full blown functional programming language along with a very rich (and poorly documented, niche, only second to C++ template in error comprehens…

Wow, this is literally the story of my team. Luckily there’s enough autonomy for us the escape the gravitational pull of the few remaining evangelists, but this is essentially what led us to this point.

I think that's kind of sad. There are a lot of good technologies that require some investment to understand them and a lot of worse is better approaches that end in a mayhem that is ultimately a terrible work environment.

For a while it seemed like investment would win but now I think we will have massive tombs of poorly written stuff that can only be worked around with even more LLM generated solutions. It is like the software bloat problem we've had recently but on steroids.

Re: Why We're Moving on from Nix

#136
post #50
post #23

Okay I'm a Nix enthusiast but you'll have to trust me when I say that I'm not criticizing them for moving away from Nix; it isn't that strong of an emotional attachment. However, I'm not really sure I understand some of these complaints and they really could use more explanation. For example: > The biggest problem with Nix is its commit-based package versioning. Only the latest major version of each package is availa…

Honestly this feels more like rail... wants to make their own version, hence a new railX lol

Correct

Re: Why We're Moving on from Nix

#137
post #91
post #59

Nix strikes me as an incredibly well thought out solution to a set of problems that should not exist. The OS should be immutable. Apps and services and drivers/extensions should be self contained. Things should not be installed “on” the OS. This entire concept is a trillion dollar mistake.

Everything you said "should" is exactly what Nix and NixOS is.

The problem is that "should" is papered over a system not designed that way from the start, and in a heterogeneous world which operates in its own way, not Nix's way.

So it's just an eternal battle between the real world and the fantasy Nix world, built on an army of thousands of volunteers writing up .nix files and contributing packages, and trying to tame the beast of Unix complexity.

Except most of us are just trying to get things done and now I work in a shop where I can't even run a development setup with my favoured IDE, or just "cargo run" my package, because Nix has been placed in the middle of everything.

Clearly in a sincere effort to tame complexity, but in the process creating a whole new world of it, with a lot of normative lifestyle assumptions.

To me... in my experience... Nix promises a lot more than it can realistically deliver, comes with a totalizing world view, and in practice ends up making life more complicated unless you completely and totally buy into its way of doing everything, and are willing to leave many of your old tools and practices behind.

Re: Why We're Moving on from Nix

#138
post #82
post #23

Okay I'm a Nix enthusiast but you'll have to trust me when I say that I'm not criticizing them for moving away from Nix; it isn't that strong of an emotional attachment. However, I'm not really sure I understand some of these complaints and they really could use more explanation. For example: > The biggest problem with Nix is its commit-based package versioning. Only the latest major version of each package is availa…

I think the part that's easy to miss is that their users are devs who will want to specify their own dependencies and versions for arbitrary packages. The way nix works with the way nixpkgs is structured, pinning a version of any package means pinning a commit of the entire nixpkgs tree. Since package builds of node/python/ruby packages depend on stuff outside of the package dir in the tree, you need that mapping bet…

> The way nix works with the way nixpkgs is structured, pinning a version of any package means pinning a commit of the entire nixpkgs tree.

You can do that for a single package. For example, the latest version of linux-firmware is currently broken for my wifi cards so I pinned linux-firmware to commit dda3dcd3f of nixpkgs, whereas the rest of my software comes from the latest version of nixpkgs. There are multiple ways to accomplish this, but the way I did it was:

1. Add an input of a specific version of nixpkgs (which I called `nixpkgs-dda3dcd3f`): https://code.fizz.buzz/talexander/machine_setup/src/commit/e...

2. Add an "overlay" which replaces linux-firmware in the regular nixpkgs with the copy from nixpkgs-dda3dcd3f: https://code.fizz.buzz/talexander/machine_setup/src/commit/e...

Re: Why We're Moving on from Nix

#139
post #91

Earlier quoted context omitted.

Everything you said "should" is exactly what Nix and NixOS is.

The problem is that "should" is papered over a system not designed that way from the start, and in a heterogeneous world which operates in its own way, not Nix's way. So it's just an eternal battle between the real world and the fantasy Nix world, built on an army of thousands of volunteers writing up .nix files and contributing packages, and trying to tame the beast of Unix complexity. Except most of us are just try…

The right way to tame complexity is not that much of a hassle. This is why virtualization and containers have been so successful. Make the OS immutable by converting into a nested Russian doll of OSes with specific instances being mutable but also disposable.

It’s ugly in its own way but it has the virtue of not exchanging one ugly complexity tax (OS rot and manual admin) with another (a complicated “manager” that wants to get in the way).

Re: Why We're Moving on from Nix

#140
post #139

Earlier quoted context omitted.

The problem is that "should" is papered over a system not designed that way from the start, and in a heterogeneous world which operates in its own way, not Nix's way. So it's just an eternal battle between the real world and the fantasy Nix world, built on an army of thousands of volunteers writing up .nix files and contributing packages, and trying to tame the beast of Unix complexity. Except most of us are just try…

The right way to tame complexity is not that much of a hassle. This is why virtualization and containers have been so successful. Make the OS immutable by converting into a nested Russian doll of OSes with specific instances being mutable but also disposable. It’s ugly in its own way but it has the virtue of not exchanging one ugly complexity tax (OS rot and manual admin) with another (a complicated “manager” that wa…

I kind of dig the idea of a unikernel world where there's just a hypervisor and applications running directly on top of it shipping only the bits of the OS they need.
Post reply on HN