Untable Plasma, stable the rest

Hello,

I’d be interested in having all my packages update from the stable channel, except for packages under the plasma-desktop pattern: those I want to update from the unstable channel.

Kind users from the Telegram group has given me directions already, i.e. applying the overlay

self: super: { plasma-desktop = unstable.plasma-desktop; }

while subscribing only to the stable channel.

Two questions:

  1. Is this approach recommended against or does it introduce unnecessary risks?
  2. What other assumptions does this approach require? I was told that I also needed to use flaks, but I am not sure I see why and how to to that.

Thanks in advance!

1 Like

For desktop users, I would actually recommend using unstable. But it’s hard to quantify risk with plasma since there’s so much runtime behavior.

You don’t need to use flakes, it would allow you to have more control in tracking changes to the underlying nixpkgs package set, but not a requirement.

The only thing which likely won’t work consistently is running from unstable by default, then cherry-picking gui applications built with an older version of glibc (stable has glibc==2.31, unstable has glibc==2.32). Glibc will throw a “missing symbols” error if loads your system’s video drivers first due to the impure usage of /run/opengl-driver/lib in the runpath.

Besides what @jonringer says, this does have the downside that there will be quite a large number of duplicate dependencies. Since the glibc has changed since 20.09, any dependency (glibc, libX11, Qt, etc.) that is shared by Plasma and any program that is installed from 20.09 will be twice in the store (at the 20.09 version and unstable version). Of course, this is not a problem if you have enough disk space and RAM (since more dynamic libraries will be loaded).

I agree with @jonringer that for desktop use, running is unstable definitely worth considering. I have run unstable pretty much since I started using NixOS 2.5 years ago and it does not break that often. If there is breakage, it typically means that you just can’t build a new generation until the issue is fixed. In the rare case where a new generation can be built, but is unusable, you can always boot into the previous working generation.

Besides that, you can keep track of known-good nixpkgs unstable versions by putting your NixOS configuration in a git repository and pinning the nixpkgs version. You can do this with flakes, however flakes require an unstable Nix version, which still has bugs quite regularly. A more conservative option is to use niv to pin nixpkgs, which works well with the stable version of Nix.

1 Like

@jonringer @danieldk Thank you very much, this kind of quality answers really set apart forums in general and these forums in particular!

I’ll globally switch to the unstable channel then. I am used to rolling-release distributions with rollback features so this is not at all a problem for me.