Closed montchr closed 1 year ago
Looking into it. Thanks!
Thank you! That was probably the fastest response I have ever seen anywhere 😄
@blaggacao Unfortunately I'm still getting this error in the same location even after nix flake update
.
Ran into this too, I think the types
argument is shadowed by the inherit (lib) types
further down: https://github.com/divnix/std/blob/01ced7d1415f8a62e9b608bece1f81f95a9d09ca/src/flakeModule.nix#L32
I guess we can close. Sorry for the inconveniences and thank you for your collaboration in fixing!
If it turn out not fixed, we can reopen (again) : 😊
I'm using
std
through the flake-parts module, which was working well until a few weeks ago when I started getting the following error after updating inputs:Here is my
flake.nix
:https://github.com/montchr/dotfield/blob/d9fd62dbf2f6c4f3f8e61cf0b0f87123de720459/flake.nix
I've been busy so have been avoiding the update. In another simpler project I got the same issue but wasn't really using the features of
flake-parts
so I just switched it to use Standard'smkFlake
.Full Output
```console $ nix develop --show-trace error: … while evaluating call site at «none»:0: (source not available) … while calling anonymous lambda at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/attrsets.nix:716:24: 715| let f = attrPath: 716| zipAttrsWith (n: values: | ^ 717| let here = attrPath ++ [n]; in … while evaluating call site at «none»:0: (source not available) … while calling 'g' at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/attrsets.nix:535:19: 534| g = 535| name: value: | ^ 536| if isAttrs value && cond value … while evaluating call site at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/attrsets.nix:538:20: 537| then recurse (path ++ [name]) value 538| else f (path ++ [name]) value; | ^ 539| in mapAttrs g; … while calling anonymous lambda at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:270:72: 269| # For definitions that have an associated option 270| declaredConfig = mapAttrsRecursiveCond (v: ! isOption v) (_: v: v.value) options; | ^ 271| … while evaluating the attribute 'value' at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:728:9: 727| in warnDeprecation opt // 728| { value = builtins.addErrorContext "while evaluating the option `${showOption loc}':" value; | ^ 729| inherit (res.defsFinal') highestPrio; … while evaluating the option `flake.devShells': … while evaluating the attribute 'mergedValue' at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:763:5: 762| # Type-check the remaining definitions, and merge them. Or throw if no definitions. 763| mergedValue = | ^ 764| if isDefined then … while evaluating the attribute 'values' at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:757:9: 756| in { 757| values = defs'''; | ^ 758| inherit (defs'') highestPrio; … while evaluating the attribute 'values' at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:856:7: 855| in { 856| values = concatMap (def: if getPrio def == highestPrio then [(strip def)] else []) defs; | ^ 857| inherit highestPrio; … while evaluating call site at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:743:17: 742| # Process mkMerge and mkIf properties. 743| defs' = concatMap (m: | ^ 744| map (value: { inherit (m) file; inherit value; }) (builtins.addErrorContext "while evaluating definitions from `${m.file}':" (dischargeProperties m.value)) … while calling anonymous lambda at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:743:28: 742| # Process mkMerge and mkIf properties. 743| defs' = concatMap (m: | ^ 744| map (value: { inherit (m) file; inherit value; }) (builtins.addErrorContext "while evaluating definitions from `${m.file}':" (dischargeProperties m.value)) … while evaluating definitions from `/nix/store/02cdqdy8973dvz5g7ny2sli8nyan8cgm-source/src/flakeModule.nix': … while evaluating call site at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:744:137: 743| defs' = concatMap (m: 744| map (value: { inherit (m) file; inherit value; }) (builtins.addErrorContext "while evaluating definitions from `${m.file}':" (dischargeProperties m.value)) | ^ 745| ) defs; … while calling 'dischargeProperties' at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:815:25: 814| */ 815| dischargeProperties = def: | ^ 816| if def._type or "" == "merge" then … while evaluating the attribute 'value' at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:568:44: 567| defnsByName' = byName "config" (module: value: 568| [{ inherit (module) file; inherit value; }] | ^ 569| ) configs; … while evaluating call site at «none»:0: (source not available) … while calling anonymous lambda at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/attrsets.nix:716:24: 715| let f = attrPath: 716| zipAttrsWith (n: values: | ^ 717| let here = attrPath ++ [n]; in … while evaluating call site at «none»:0: (source not available) … while calling anonymous lambda at /nix/store/02cdqdy8973dvz5g7ny2sli8nyan8cgm-source/src/flakeModule.nix:167:32: 166| picked = mapAttrs (_: v: pick grown v) cfg.pick; 167| harvested = mapAttrs (_: v: harvest grown v) cfg.harvest; | ^ 168| winnowed = zipAttrsWith (n: v: winnow (head v) grown (head (tail v))) [cfg.winnowIf cfg.winnow]; … while evaluating call site at /nix/store/02cdqdy8973dvz5g7ny2sli8nyan8cgm-source/src/flakeModule.nix:167:35: 166| picked = mapAttrs (_: v: pick grown v) cfg.pick; 167| harvested = mapAttrs (_: v: harvest grown v) cfg.harvest; | ^ 168| winnowed = zipAttrsWith (n: v: winnow (head v) grown (head (tail v))) [cfg.winnowIf cfg.winnow]; … while calling 'winnow' at /nix/store/9s0v10x254r4d8i5651spf9z2s0ycswc-source/soil/winnow.nix:22:21: 21| */ 22| winnow = pred: t: p: let | ^ 23| multiplePaths = l.isList (l.elemAt p 0); … while evaluating call site at /nix/store/9s0v10x254r4d8i5651spf9z2s0ycswc-source/soil/winnow.nix:44:10: 43| if multiplePaths 44| then l.foldl' l.recursiveUpdate {} (map (path: hoist path) p) | ^ 45| else hoist p; … while calling 'recursiveUpdate' at /nix/store/gm8c760jh9w22vybdj99g1ciz2npmj7c-source/lib/attrsets.nix:752:5: 751| # Right attribute set of the merge. 752| rhs: | ^ 753| recursiveUpdateUntil (path: lhs: rhs: !(isAttrs lhs && isAttrs rhs)) lhs rhs; … while evaluating call site at /nix/store/gm8c760jh9w22vybdj99g1ciz2npmj7c-source/lib/attrsets.nix:753:5: 752| rhs: 753| recursiveUpdateUntil (path: lhs: rhs: !(isAttrs lhs && isAttrs rhs)) lhs rhs; | ^ 754| … while calling 'recursiveUpdateUntil' at /nix/store/gm8c760jh9w22vybdj99g1ciz2npmj7c-source/lib/attrsets.nix:714:5: 713| # Right attribute set of the merge. 714| rhs: | ^ 715| let f = attrPath: … while evaluating call site at «none»:0: (source not available) … while calling anonymous lambda at /nix/store/9s0v10x254r4d8i5651spf9z2s0ycswc-source/soil/winnow.nix:44:46: 43| if multiplePaths 44| then l.foldl' l.recursiveUpdate {} (map (path: hoist path) p) | ^ 45| else hoist p; … while evaluating call site at /nix/store/9s0v10x254r4d8i5651spf9z2s0ycswc-source/soil/winnow.nix:44:52: 43| if multiplePaths 44| then l.foldl' l.recursiveUpdate {} (map (path: hoist path) p) | ^ 45| else hoist p; … while calling 'hoist' at /nix/store/9s0v10x254r4d8i5651spf9z2s0ycswc-source/soil/winnow.nix:24:13: 23| multiplePaths = l.isList (l.elemAt p 0); 24| hoist = path: | ^ 25| l.mapAttrs ( … while evaluating call site at /nix/store/9s0v10x254r4d8i5651spf9z2s0ycswc-source/soil/winnow.nix:35:9: 34| ( 35| l.filterAttrs ( | ^ 36| n: v: … while calling 'filterAttrs' at /nix/store/gm8c760jh9w22vybdj99g1ciz2npmj7c-source/lib/attrsets.nix:305:5: 304| # The attribute set to filter 305| set: | ^ 306| listToAttrs (concatMap (name: let v = set.${name}; in if pred name v then [(nameValuePair name v)] else []) (attrNames set)); … while evaluating call site at /nix/store/gm8c760jh9w22vybdj99g1ciz2npmj7c-source/lib/attrsets.nix:306:18: 305| set: 306| listToAttrs (concatMap (name: let v = set.${name}; in if pred name v then [(nameValuePair name v)] else []) (attrNames set)); | ^ 307| … while calling anonymous lambda at /nix/store/gm8c760jh9w22vybdj99g1ciz2npmj7c-source/lib/attrsets.nix:306:29: 305| set: 306| listToAttrs (concatMap (name: let v = set.${name}; in if pred name v then [(nameValuePair name v)] else []) (attrNames set)); | ^ 307| … while evaluating call site at /nix/store/gm8c760jh9w22vybdj99g1ciz2npmj7c-source/lib/attrsets.nix:306:62: 305| set: 306| listToAttrs (concatMap (name: let v = set.${name}; in if pred name v then [(nameValuePair name v)] else []) (attrNames set)); | ^ 307| … while calling anonymous lambda at /nix/store/9s0v10x254r4d8i5651spf9z2s0ycswc-source/soil/winnow.nix:36:14: 35| l.filterAttrs ( 36| n: v: | ^ 37| (l.elem n l.systems.doubles.all) # avoids infinit recursion … while evaluating call site at /nix/store/9s0v10x254r4d8i5651spf9z2s0ycswc-source/soil/winnow.nix:38:17: 37| (l.elem n l.systems.doubles.all) # avoids infinit recursion 38| && (l.hasAttrByPath path v) | ^ 39| ) … while calling 'hasAttrByPath' at /nix/store/gm8c760jh9w22vybdj99g1ciz2npmj7c-source/lib/attrsets.nix:60:5: 59| # The nested attribute set to check 60| e: | ^ 61| let attr = head attrPath; … while evaluating call site at «none»:0: (source not available) … while calling anonymous lambda at /nix/store/gm8c760jh9w22vybdj99g1ciz2npmj7c-source/lib/attrsets.nix:716:24: 715| let f = attrPath: 716| zipAttrsWith (n: values: | ^ 717| let here = attrPath ++ [n]; in … while evaluating call site at /nix/store/9s0v10x254r4d8i5651spf9z2s0ycswc-source/grow/default.nix:181:13: 180| ]; # }; 181| res = accumulate (l.map loadCellFor cells'); | ^ 182| in [ … while calling anonymous lambda at /nix/store/9s0v10x254r4d8i5651spf9z2s0ycswc-source/grow/newHelpers.nix:8:12: 7| ( 8| acc: new: let | ^ 9| first = l.head new; … while evaluating call site at «none»:0: (source not available) … while calling anonymous lambda at /nix/store/gm8c760jh9w22vybdj99g1ciz2npmj7c-source/lib/attrsets.nix:479:10: 478| attrs: 479| map (name: f name attrs.${name}) (attrNames attrs); | ^ 480| … while evaluating call site at /nix/store/gm8c760jh9w22vybdj99g1ciz2npmj7c-source/lib/attrsets.nix:479:16: 478| attrs: 479| map (name: f name attrs.${name}) (attrNames attrs); | ^ 480| … while calling anonymous lambda at /nix/store/9s0v10x254r4d8i5651spf9z2s0ycswc-source/types/cell.nix:5:46: 4| cellBlockPath, 5| }: originFlake: cellsFrom: cellBlocks: cell: type: let | ^ 6| path = cellBlockPath (cellPath cellsFrom cell); … while evaluating call site at /nix/store/9s0v10x254r4d8i5651spf9z2s0ycswc-source/grow/newProcessCfg.nix:31:8: 30| (unique 31| (BlockTypes "${origin "cellBlocks"} - grow[On]:cellBlocks" cellBlocks)) | ^ 32| .result; … while calling '__functor' at /nix/store/8kdkvnx9ihzl6whx8q70wmhidmk3lpxq-source/flake.nix:69:27: 68| # function. 69| __functor = self: value: let | ^ 70| result = self.checkType value; … while evaluating call site at /nix/store/8kdkvnx9ihzl6whx8q70wmhidmk3lpxq-source/flake.nix:72:14: 71| in 72| if checkToBool result | ^ 73| then value … while calling anonymous lambda at /nix/store/8kdkvnx9ihzl6whx8q70wmhidmk3lpxq-source/flake.nix:45:24: 44| checkType, 45| checkToBool ? (result: result.ok), | ^ 46| toError ? (_: result: result.err), … while evaluating call site at /nix/store/8kdkvnx9ihzl6whx8q70wmhidmk3lpxq-source/flake.nix:70:20: 69| __functor = self: value: let 70| result = self.checkType value; | ^ 71| in … while calling 'checkType' at /nix/store/8kdkvnx9ihzl6whx8q70wmhidmk3lpxq-source/flake.nix:174:27: 173| name = "list<${t.name}>"; 174| checkType = v: | ^ 175| if isList v … while evaluating the attribute 'cellBlocks' at /nix/store/02cdqdy8973dvz5g7ny2sli8nyan8cgm-source/src/flakeModule.nix:163:29: 162| # access them explicitly to trigger a module system error if not defined 163| inherit (cfg.grow) cellsFrom cellBlocks; | ^ 164| } … while evaluating call site at «none»:0: (source not available) … while calling 'g' at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/attrsets.nix:535:19: 534| g = 535| name: value: | ^ 536| if isAttrs value && cond value … while evaluating call site at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/attrsets.nix:538:20: 537| then recurse (path ++ [name]) value 538| else f (path ++ [name]) value; | ^ 539| in mapAttrs g; … while calling anonymous lambda at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:270:72: 269| # For definitions that have an associated option 270| declaredConfig = mapAttrsRecursiveCond (v: ! isOption v) (_: v: v.value) options; | ^ 271| … while evaluating the attribute 'value' at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:728:9: 727| in warnDeprecation opt // 728| { value = builtins.addErrorContext "while evaluating the option `${showOption loc}':" value; | ^ 729| inherit (res.defsFinal') highestPrio; … while evaluating the option `std.grow.cellBlocks': … while evaluating the attribute 'mergedValue' at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:763:5: 762| # Type-check the remaining definitions, and merge them. Or throw if no definitions. 763| mergedValue = | ^ 764| if isDefined then … while evaluating call site at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:765:12: 764| if isDefined then 765| if all (def: type.check def.value) defsFinal then type.merge loc defsFinal | ^ 766| else let allInvalid = filter (def: ! type.check def.value) defsFinal; … while calling anonymous lambda at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/modules.nix:765:17: 764| if isDefined then 765| if all (def: type.check def.value) defsFinal then type.merge loc defsFinal | ^ 766| else let allInvalid = filter (def: ! type.check def.value) defsFinal; … while evaluating the attribute 'check' at /nix/store/dxfmn2pdvvpiark08jlwc8s8gkhviiw1-source/lib/types.nix:179:14: 178| { _type = "option-type"; 179| inherit | ^ 180| name check merge emptyValue getSubOptions getSubModules substSubModules error: attribute 'BlockTypes' missing at /nix/store/02cdqdy8973dvz5g7ny2sli8nyan8cgm-source/src/flakeModule.nix:70:14: 69| descriptionClass = "noun"; 70| inherit (types.BlockTypes) check; | ^ 71| }; ```