!VRULIdgoKmKPzJZzjj:nixos.org

Nix Hackers

884 Members
For people hacking on the Nix package manager itself189 Servers

Load older messages


SenderMessageTime
31 Mar 2025
@Ericson2314:matrix.orgJohn Ericsonthe marginial cost of the split package feels very low to me21:18:09
@emilazy:matrix.orgemilyin which case we would be free to break the old way in 25.1121:18:14
@Ericson2314:matrix.orgJohn Ericsonbecause we can simply test all the things you mentioned right away21:18:20
@Ericson2314:matrix.orgJohn Ericsonthere aren't really latant issues21:18:24
@Ericson2314:matrix.orgJohn Ericsonyou mean a patching mechanism that works with split and unsplit packages?21:19:26
@Ericson2314:matrix.orgJohn EricsonI am not sure, probably not21:19:31
@emilazy:matrix.orgemilyhow people consume our packages is a tragic unknown. though of course we always have to draw a line somewhere but look at how breaking changes to lib are handled for how our caution should increase as the criticality does21:19:36
@emilazy:matrix.orgemilyand again if we were keeping packaging constant but bumping version or vice versa (not possible in this case, I know), there would still be concerns but of lower magnitude21:20:18
@Ericson2314:matrix.orgJohn EricsonI'm thinking about it21:28:38
@Ericson2314:matrix.orgJohn Ericson(but I also walked out to eat)21:34:03
@trofi:matrix.org@trofi:matrix.org I wonder what it would look like if every single nixpkgs package had their own unique helper to apply patches and change depends :) 21:35:47
@roberthensing:matrix.orgroberthit's a package set21:49:10
@roberthensing:matrix.orgroberthactually I think it would be great, because we'd settle on a standard interface for doing just those things and nothing else, and we'll finally have an interface boundary21:49:57
@roberthensing:matrix.orgroberthoverriding arbitrary internals would be frowned upon, because that is not a testable or maintainable interface. Instead, users would contribute functions, tests, and documentation to support their use cases instead of trying to work around the unpredictable internal changes in packages. It'd be glorious21:53:02
@raitobezarius:matrix.orgraitobezarius
In reply to @elvishjerricco:matrix.org
raitobezarius: I would like to know an example I could use to verify whether or not Nix actually has the problem you describe.
nix-eval-jobs with nix 2.X and 2.Y the entirety of nixpkgs and then compare the outPath?
21:59:36
@llakala:matrix.orgllakala
In reply to @trofi:matrix.org
I wonder what it would look like if every single nixpkgs package had their own unique helper to apply patches and change depends :)
applyPatches does this in some sense, but with IFD...
22:00:14
@llakala:matrix.orgllakalahopefully we can eventually get to the point where IFD isn't a problem22:00:37
@llakala:matrix.orgllakalaas Tvix/Snix shows us, it is indeed possible22:01:01
@raitobezarius:matrix.orgraitobezarius
In reply to @roberthensing:matrix.org
overriding arbitrary internals would be frowned upon, because that is not a testable or maintainable interface. Instead, users would contribute functions, tests, and documentation to support their use cases instead of trying to work around the unpredictable internal changes in packages. It'd be glorious

i kinda disagree with this portrayal of the current state of things, there was a naturally developed API for overriding packages which is explained in Nix pills and stuff, overrideAttrs has some standard expectations: you can override patches, etc, etc.

this all solidified quite well without many efforts thanks to automatic injection of these attributes and pushing packagers to use a set of mostly standard APIs, of course, some packagers went their own way, e.g. python3Packages and the suffering caused by that is reported constantly in the well known issue, I don't think a day passed with people saying "I'm glad that python3Packages has its own API for override and its own contract" that no one knows

having an API to inject your own override / overrideAttrs is 95 % of the time not needed, most packages have absolutely boring needs

22:03:38
@raitobezarius:matrix.orgraitobezarius the interface boundary kinda exist today, it just is not super well made for package sets indeed, but there's already a bunch of this that already works and arguably the Nix implementation is even more complicated than a trivial package set and the current situation with nixForLinking does not really address the "let me choose my Nix version while importing nixpkgs once" 22:04:56
@roberthensing:matrix.orgroberthyeah I was replying to trofi's scenario :)22:07:06
@roberthensing:matrix.orgroberthnot the current state of things22:07:16
@trofi:matrix.org@trofi:matrix.orgheh :)22:07:35
@raitobezarius:matrix.orgraitobezariusi may read too much into what trofi said22:07:42
@raitobezarius:matrix.orgraitobezariusbut i thought it would describe a smaller or more-difficult-to-maintain nixpkgs ;P22:07:54
@roberthensing:matrix.orgroberthwith the new packaging we've tried to stick as much to established APIs like plain mkDerivation without added fixed-points on top22:10:07
@trofi:matrix.org@trofi:matrix.org I had to throw away a bunch of .nix code that added env.NIX_CFLAGS_COMPILE =" -D_GLIBCXX_DEBUG"; to nix package because I have no idea how to do it for nix-2.26. For other package sets in nixpkgs my default action of to stick a patch into local nixpkgs checkout because I have no idea how they work from a set to a set. 22:10:17
@roberthensing:matrix.orgroberthI think the packaging layers we've developed for mkDerivation could be useful outside Nix for other meson-based projects22:10:46
@raitobezarius:matrix.orgraitobezariusas I kind of have joint authority over the Nixpkgs packaging of Lix, I read it but I'm not super convinced personally22:11:27
@raitobezarius:matrix.orgraitobezariusI feel like it violates too the principle of least astonishment for packagers and consumers22:11:37

Show newer messages


Back to Room ListRoom Version: 6