!djTaTBQyWEPRQxrPTb:nixos.org

Nixpkgs Architecture Team

230 Members
https://github.com/nixpkgs-architecture, weekly public meetings on Wednesday 15:00-16:00 UTC at https://meet.jit.si/nixpkgs-architecture51 Servers

You have reached the beginning of time (for this room).


SenderMessageTime
11 Oct 2023
@piegames:matrix.org@piegames:matrix.org On the other hand, shouldn't this still work as long as the package set doesn't define a callPackage? Because stuff is lazy etc. 14:43:28
@piegames:matrix.org@piegames:matrix.orgWell, attribute names are not, but still14:43:39
@infinisil:matrix.orginfinisilActually lazy attribute sets would allow this: https://github.com/NixOS/nix/issues/409014:43:59
@infinisil:matrix.orginfinisil piegames: It can't now whether it defines a callPackage without evaluating it 14:44:25
@tomberek:matrix.orgtomberek lazy attrsets... lazy attsets ... lazy attrsets. Or __getter (https://github.com/NixOS/nix/issues/8187#issuecomment-1501258036) or builtins.mkProxy..... or something 14:45:43
@piegames:matrix.org@piegames:matrix.orgHm, are there any other ways to solve my current problem?14:45:53
@piegames:matrix.org@piegames:matrix.orgHow does by-name work around this?14:46:01
@piegames:matrix.org@piegames:matrix.orgWhile I do approve of the function-as-attrset idea, I have a very strong aversion towards underscoreunderscore magic attribute names, and generally want to see less of them in the language14:47:29
@infinisil:matrix.orginfinisil piegames: The attribute names of pkgs/by-name don't depend on final, they're only computed using lib 15:28:58
@infinisil:matrix.orginfinisilSee https://github.com/NixOS/nixpkgs/blob/master/pkgs/top-level/by-name-overlay.nix15:29:17
@piegames:matrix.org@piegames:matrix.org but it does self.callPackage? 15:30:10
@infinisil:matrix.orginfinisil piegames: It doesn't need that to compute the attribute names though 15:31:47
@infinisil:matrix.orginfinisil It's only the attribute values defined using callPackage, which is the same as all-packages.nix 15:32:15
@tomberek:matrix.orgtomberekmaking it a builtin is another way to do it15:33:07
@piegames:matrix.org@piegames:matrix.org But what is one puts some by-name/callPackage in there? (hypothetically) 15:34:39
@infinisil:matrix.orginfinisil piegames: The order of overlays would determine which one gets the final (hah) say: https://github.com/NixOS/nixpkgs/blob/master/pkgs/top-level/stage.nix#L284-L295 15:37:49

Show newer messages


Back to Room ListRoom Version: 9