Wrote thoughts about how Flakes got to the point it is.
There’s also some thoughts about what it means to me, in reality. And some opinions.
EDIT: Since I’ve been asked: this is not a direct response to any other post, but a write-up I was working on over the past weeks.
The central point appears to be that the integrated festures in question aren’t mature or aren’t “finished”, but there is scant evidence provided to support that claim. Many people use flakes right now and aren’t complaining about stability issues or bugs. I was anxious and didn’t migrate my config to flakes for over a year because it was intimidating and scary, but once I did, I realized how simple and easy it was and the new CLI and lock files are great. I look forward to channels going away.
The central point is that many are, or are close to be, but held back by either other less finished features, integration between features, or due to lack of resources to properly evaluate and determine if it is something that can be worth supporting in the extremely long time.
EDIT: Forgot to state that the vagueness around claims of what is and isn’t stable is by design: it doesn’t matter for the message. The message is that it’s too much all at once. Flakes is being blocked by itself.
(Forgot to reply to the other half)
I was anxious and didn’t migrate my config to flakes for over a year because it was intimidating and scary, but once I did, I realized how simple and easy it was and the new CLI and lock files are great. I look forward to channels going away.
Channels is an overloaded terminology. I suspect this is about the
nix-channel helper that uses profiles to “pin” a repo into the Nix store using the Nix profiles system.
Channels were never necessary. It’s been 6+ years I’ve setup NixOS and I have only used channels in the beginning month or two, before focusing in on the intrinsic problems with managing them. So make sure you don’t confuse Flakes with them being strictly a replacement to
nix-channel, or being only about locking inputs.
And I don’t think that vague fear of the unknown is the main issue for anyone having issues with Flakes. There are many legit reasons to not use Flakes yet, even the simplest one being that it’s not being marked stable yet.
Here’s a story to support “monolith” part:
Where I work, we use nix as a build system. One of the main things that separates nix from real build systems (ones designed for that from the beginning) like
bazel is that the real ones detect the rebuild set quickly. Nix’s evaluation slowness here is a real problem, as a result we wind up with parallel
ghc --make or ninja systems for interactive use. There was occasionally the thought that this could be open-sourced and could be a plausible alternative to
bazel which had just been open-sourced at the time and had many limitations. It didn’t happen due to not enough time, but slow evaluation was definitely one of the things at top of mind that made me think it wasn’t worth allocating the time.
When flakes was first announced it seemed like it could fix this by caching unchanged nix files, and maybe it could have. But it seems like it wound up too tangled up in the other aspects of flakes and is not general purpose. Of course to use any feature in a chaotic open source project means you have to be willing to do patches to adapt it to your case and fix bugs, but for flakes my impression is that this would be working against the grain of their design and probably a significant amount of work, and would not be acceptable upstream. So far I haven’t even seriously looked into it, but would like to some day.