Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't use nightly overlay with NixOS 24.05 #547

Closed
TeleVoyant opened this issue Jun 3, 2024 · 16 comments
Closed

Can't use nightly overlay with NixOS 24.05 #547

TeleVoyant opened this issue Jun 3, 2024 · 16 comments

Comments

@TeleVoyant
Copy link

error: undefined variable 'neovim-nightly'

[sudo] password for niel: 
unpacking channels...
unpacking channels...
building Nix...
building the system configuration...
error:
       … while calling the 'head' builtin

         at /nix/store/k1i8sghsbwcwgw43mglmf634rc9p9mm8-nixos-23.11/nixos/lib/attrsets.nix:922:11:

          921|         || pred here (elemAt values 1) (head values) then
          922|           head values
             |           ^
          923|         else

       … while evaluating the attribute 'value'

         at /nix/store/k1i8sghsbwcwgw43mglmf634rc9p9mm8-nixos-23.11/nixos/lib/modules.nix:807:9:

          806|     in warnDeprecation opt //
          807|       { value = builtins.addErrorContext "while evaluating the option `${showOption loc}':" value;
             |         ^
          808|         inherit (res.defsFinal') highestPrio;

       (stack trace truncated; use '--show-trace' to show the full trace)

       error: undefined variable 'neovim-nightly'

       at /etc/nixos/configuration.nix:389:5:

          388|     # dev env
          389|     neovim-nightly # 1st favourite editor (nightly builds)
             |     ^
          390|     #neovim # 1st favourite editor

Screenshot from 2024-06-03 21-22-33

@TeleVoyant
Copy link
Author

TeleVoyant commented Jun 3, 2024

help... v0.9.4 is such a downgrade, warnings and random errors keep on distracting me.

@willruggiano
Copy link
Contributor

It's not neovim-nightly anymore, just neovim

@TeleVoyant
Copy link
Author

TeleVoyant commented Jun 5, 2024

changed it from neovim-nightly to neovim

now i have a new fleet of errors, something about duplications:

unpacking channels...
unpacking channels...
building Nix...
building the system configuration...
error:
       … while calling the 'head' builtin

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:1575:11:

         1574|         || pred here (elemAt values 1) (head values) then
         1575|           head values
             |           ^
         1576|         elsewhile evaluating the attribute 'value'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:809:9:

          808|     in warnDeprecation opt //
          809|       { value = builtins.addErrorContext "while evaluating the option `${showOption loc}':" value;
             |         ^
          810|         inherit (res.defsFinal') highestPrio;

       (stack trace truncated; use '--show-trace' to show the full trace)

       error: cannot coerce a set to a string

I'm more confused, cause there ain't any other "neovim" called.

Here is my overlay code block:

 # List of Overlays, containing configuration for installing neovim's nightly packages
  nixpkgs.overlays = [
    (import (builtins.fetchTarball {
      url = "https://github.com/nix-community/neovim-nightly-overlay/archive/master.tar.gz";
    }))
  ];

@willruggiano
Copy link
Contributor

willruggiano commented Jun 5, 2024

What does --show-trace say? This seems like #533

@willruggiano
Copy link
Contributor

Make sure you read that issue and have a recent version of nixpkgs installed on your system. This is explicitly stated in the aforementioned issue;

This advice applies particularly to those of you ... that use the flake's default overlay

There are links to various commits (both good and bad, indicated inline). Compare these to what you have installed locally.

@TeleVoyant
Copy link
Author

TeleVoyant commented Jun 6, 2024

I've read the issue #533,
still i thought it would not affect me as i have not enabled flakes,
unless its enabled by default in nixos 24.05

here is the trace:

unpacking channels...
unpacking channels...
building Nix...
building the system configuration...
error:
       … while calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:1571:24:

         1570|     let f = attrPath:
         1571|       zipAttrsWith (n: values:
             |                        ^
         1572|         let here = attrPath ++ [n]; inwhile calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:1205:18:

         1204|         mapAttrs
         1205|           (name: value:
             |                  ^
         1206|             if isAttrs value && cond valuefrom call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:1208:18:

         1207|             then recurse (path ++ [ name ]) value
         1208|             else f (path ++ [ name ]) value);
             |                  ^
         1209|     inwhile calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:242:72:

          241|           # For definitions that have an associated option
          242|           declaredConfig = mapAttrsRecursiveCond (v: ! isOption v) (_: v: v.value) options;
             |                                                                        ^
          243|

       … while evaluating the option `system.build.toplevel':

       … while calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:824:28:

          823|         # Process mkMerge and mkIf properties.
          824|         defs' = concatMap (m:
             |                            ^
          825|           map (value: { inherit (m) file; inherit value; }) (builtins.addErrorContext "while evaluating definitions from `${m.file}':" (dischargeProperties m.value))while evaluating definitions from `/nix/var/nix/profiles/per-user/root/channels/nixos/nixos/modules/system/activation/top-level.nix':

       … from call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:825:137:

          824|         defs' = concatMap (m:
          825|           map (value: { inherit (m) file; inherit value; }) (builtins.addErrorContext "while evaluating definitions from `${m.file}':" (dischargeProperties m.value))
             |                                                                                                                                         ^
          826|         ) defs;while calling 'dischargeProperties'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:896:25:

          895|   */
          896|   dischargeProperties = def:
             |                         ^
          897|     if def._type or "" == "merge" thenfrom call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/nixos/modules/system/activation/top-level.nix:71:12:

           70|   # Replace runtime dependencies
           71|   system = foldr ({ oldDependency, newDependency }: drv:
             |            ^
           72|       pkgs.replaceDependency { inherit oldDependency newDependency drv; }while calling 'foldr'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/lists.nix:121:20:

          120|   */
          121|   foldr = op: nul: list:
             |                    ^
          122|     letfrom call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/lists.nix:128:8:

          127|         else op (elemAt list n) (fold' (n + 1));
          128|     in fold' 0;
             |        ^
          129|

       … while calling 'fold''

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/lists.nix:124:15:

          123|       len = length list;
          124|       fold' = n:
             |               ^
          125|         if n == lenfrom call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/nixos/modules/system/activation/top-level.nix:68:10:

           67|     then throw "\nFailed assertions:\n${concatStringsSep "\n" (map (x: "- ${x}") failedAssertions)}"
           68|     else showWarnings config.warnings baseSystem;
             |          ^
           69|

       … while calling 'showWarnings'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/trivial.nix:867:28:

          866|
          867|   showWarnings = warnings: res: lib.foldr (w: x: warn w x) res warnings;
             |                            ^
          868|

       … from call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/trivial.nix:867:33:

          866|
          867|   showWarnings = warnings: res: lib.foldr (w: x: warn w x) res warnings;
             |                                 ^
          868|

       … while calling 'foldr'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/lists.nix:121:20:

          120|   */
          121|   foldr = op: nul: list:
             |                    ^
          122|     letfrom call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/lists.nix:128:8:

          127|         else op (elemAt list n) (fold' (n + 1));
          128|     in fold' 0;
             |        ^
          129|

       … while calling 'fold''

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/lists.nix:124:15:

          123|       len = length list;
          124|       fold' = n:
             |               ^
          125|         if n == lenfrom call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/nixos/modules/system/activation/top-level.nix:48:16:

           47|   # makes it bootable. See `activatable-system.nix`.
           48|   baseSystem = pkgs.stdenvNoCC.mkDerivation ({
             |                ^
           49|     name = "nixos-system-${config.system.name}-${config.system.nixos.label}";while calling 'mkDerivation'

         at /nix/store/lawcvljh83j9xdl2kkiqa9yy73lf3y3k-nixos-24.05/nixos/pkgs/stdenv/generic/make-derivation.nix:46:5:

           45|   mkDerivation =
           46|     fnOrAttrs:
             |     ^
           47|       if builtins.isFunction fnOrAttrswhile calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:1205:18:

         1204|         mapAttrs
         1205|           (name: value:
             |                  ^
         1206|             if isAttrs value && cond valuefrom call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:1208:18:

         1207|             then recurse (path ++ [ name ]) value
         1208|             else f (path ++ [ name ]) value);
             |                  ^
         1209|     inwhile calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:242:72:

          241|           # For definitions that have an associated option
          242|           declaredConfig = mapAttrsRecursiveCond (v: ! isOption v) (_: v: v.value) options;
             |                                                                        ^
          243|

       … while evaluating the option `system.systemBuilderArgs':

       … from call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:846:59:

          845|       if isDefined then
          846|         if all (def: type.check def.value) defsFinal then type.merge loc defsFinal
             |                                                           ^
          847|         else let allInvalid = filter (def: ! type.check def.value) defsFinal;while calling 'merge'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/types.nix:583:20:

          582|       check = isAttrs;
          583|       merge = loc: defs:
             |                    ^
          584|         mapAttrs (n: v: v.value) (filterAttrs (n: v: v ? value) (zipAttrsWith (name: defs:

       … from call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/types.nix:584:35:

          583|       merge = loc: defs:
          584|         mapAttrs (n: v: v.value) (filterAttrs (n: v: v ? value) (zipAttrsWith (name: defs:
             |                                   ^
          585|             (mergeDefinitions (loc ++ [name]) elemType defs).optionalValuewhile calling 'filterAttrs'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:646:5:

          645|     pred:
          646|     set:
             |     ^
          647|     listToAttrs (concatMap (name: let v = set.${name}; in if pred name v then [(nameValuePair name v)] else []) (attrNames set));while calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:647:29:

          646|     set:
          647|     listToAttrs (concatMap (name: let v = set.${name}; in if pred name v then [(nameValuePair name v)] else []) (attrNames set));
             |                             ^
          648|

       … from call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:647:62:

          646|     set:
          647|     listToAttrs (concatMap (name: let v = set.${name}; in if pred name v then [(nameValuePair name v)] else []) (attrNames set));
             |                                                              ^
          648|

       … while calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/types.nix:584:51:

          583|       merge = loc: defs:
          584|         mapAttrs (n: v: v.value) (filterAttrs (n: v: v ? value) (zipAttrsWith (name: defs:
             |                                                   ^
          585|             (mergeDefinitions (loc ++ [name]) elemType defs).optionalValuewhile calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/types.nix:584:86:

          583|       merge = loc: defs:
          584|         mapAttrs (n: v: v.value) (filterAttrs (n: v: v ? value) (zipAttrsWith (name: defs:
             |                                                                                      ^
          585|             (mergeDefinitions (loc ++ [name]) elemType defs).optionalValuewhile calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:824:28:

          823|         # Process mkMerge and mkIf properties.
          824|         defs' = concatMap (m:
             |                            ^
          825|           map (value: { inherit (m) file; inherit value; }) (builtins.addErrorContext "while evaluating definitions from `${m.file}':" (dischargeProperties m.value))while evaluating definitions from `/nix/var/nix/profiles/per-user/root/channels/nixos/nixos/modules/system/activation/activatable-system.nix':

       … from call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:825:137:

          824|         defs' = concatMap (m:
          825|           map (value: { inherit (m) file; inherit value; }) (builtins.addErrorContext "while evaluating definitions from `${m.file}':" (dischargeProperties m.value))
             |                                                                                                                                         ^
          826|         ) defs;while calling 'dischargeProperties'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:896:25:

          895|   */
          896|   dischargeProperties = def:
             |                         ^
          897|     if def._type or "" == "merge" thenfrom call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/nixos/modules/system/activation/activation-script.nix:133:18:

          132|       apply = set: set // {
          133|         script = systemActivationScript set false;
             |                  ^
          134|       };while calling 'systemActivationScript'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/nixos/modules/system/activation/activation-script.nix:20:33:

           19|
           20|   systemActivationScript = set: onlyDry: let
             |                                 ^
           21|     set' = mapAttrs (_: v: if isString v then (noDepEntry v) // { supportsDryActivation = false; } else v) set;from call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/nixos/modules/system/activation/activation-script.nix:49:9:

           48|
           49|       ${textClosureMap id (withDrySnippets) (attrNames withDrySnippets)}
             |         ^
           50|

       … while calling 'textClosureMap'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/strings-with-deps.nix:75:35:

           74|
           75|   textClosureMap = f: predefined: names:
             |                                   ^
           76|     concatStringsSep "\n" (map f (textClosureList predefined names));while calling 'id'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/trivial.nix:36:8:

           35|   */
           36|   id = x: x;
             |        ^
           37|

       … while calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:1205:18:

         1204|         mapAttrs
         1205|           (name: value:
             |                  ^
         1206|             if isAttrs value && cond valuefrom call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:1208:18:

         1207|             then recurse (path ++ [ name ]) value
         1208|             else f (path ++ [ name ]) value);
             |                  ^
         1209|     inwhile calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:242:72:

          241|           # For definitions that have an associated option
          242|           declaredConfig = mapAttrsRecursiveCond (v: ! isOption v) (_: v: v.value) options;
             |                                                                        ^
          243|

       … while evaluating the option `system.activationScripts.etc.text':

       … while calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:824:28:

          823|         # Process mkMerge and mkIf properties.
          824|         defs' = concatMap (m:
             |                            ^
          825|           map (value: { inherit (m) file; inherit value; }) (builtins.addErrorContext "while evaluating definitions from `${m.file}':" (dischargeProperties m.value))while evaluating definitions from `/nix/var/nix/profiles/per-user/root/channels/nixos/nixos/modules/system/etc/etc-activation.nix':

       … from call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:825:137:

          824|         defs' = concatMap (m:
          825|           map (value: { inherit (m) file; inherit value; }) (builtins.addErrorContext "while evaluating definitions from `${m.file}':" (dischargeProperties m.value))
             |                                                                                                                                         ^
          826|         ) defs;while calling 'dischargeProperties'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:896:25:

          895|   */
          896|   dischargeProperties = def:
             |                         ^
          897|     if def._type or "" == "merge" thenwhile calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:1571:24:

         1570|     let f = attrPath:
         1571|       zipAttrsWith (n: values:
             |                        ^
         1572|         let here = attrPath ++ [n]; inwhile calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/types.nix:608:29:

          607|       merge = loc: defs:
          608|         zipAttrsWith (name: defs:
             |                             ^
          609|           let merged = mergeDefinitions (loc ++ [name]) elemType defs;while calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:824:28:

          823|         # Process mkMerge and mkIf properties.
          824|         defs' = concatMap (m:
             |                            ^
          825|           map (value: { inherit (m) file; inherit value; }) (builtins.addErrorContext "while evaluating definitions from `${m.file}':" (dischargeProperties m.value))while evaluating definitions from `/nix/var/nix/profiles/per-user/root/channels/nixos/nixos/modules/system/etc/etc.nix':

       … from call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:825:137:

          824|         defs' = concatMap (m:
          825|           map (value: { inherit (m) file; inherit value; }) (builtins.addErrorContext "while evaluating definitions from `${m.file}':" (dischargeProperties m.value))
             |                                                                                                                                         ^
          826|         ) defs;while calling 'dischargeProperties'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:896:25:

          895|   */
          896|   dischargeProperties = def:
             |                         ^
          897|     if def._type or "" == "merge" thenfrom call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:273:39:

          272|         then value
          273|         else { ${elemAt attrPath n} = atDepth (n + 1); };
             |                                       ^
          274|     in atDepth 0;while calling 'atDepth'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:270:17:

          269|       len = length attrPath;
          270|       atDepth = n:
             |                 ^
          271|         if n == lenwhile evaluating derivation 'etc'
         whose name attribute is located at /nix/store/lawcvljh83j9xdl2kkiqa9yy73lf3y3k-nixos-24.05/nixos/pkgs/stdenv/generic/make-derivation.nix:331:7while evaluating attribute 'buildCommand' of derivation 'etc'

         at /nix/store/lawcvljh83j9xdl2kkiqa9yy73lf3y3k-nixos-24.05/nixos/pkgs/build-support/trivial-builders/default.nix:68:16:

           67|         enableParallelBuilding = true;
           68|         inherit buildCommand name;
             |                ^
           69|         passAsFile = [ "buildCommand" ]from call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/nixos/modules/system/etc/etc.nix:54:7:

           53|     mkdir -p "$out/etc"
           54|     ${concatMapStringsSep "\n" (etcEntry: escapeShellArgs [
             |       ^
           55|       "makeEtcEntry"while calling 'concatMapStringsSep'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/strings.nix:116:5:

          115|     # List of input strings
          116|     list: concatStringsSep sep (map f list);
             |     ^
          117|

       … while calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/nixos/modules/system/etc/etc.nix:54:33:

           53|     mkdir -p "$out/etc"
           54|     ${concatMapStringsSep "\n" (etcEntry: escapeShellArgs [
             |                                 ^
           55|       "makeEtcEntry"from call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/nixos/modules/system/etc/etc.nix:54:43:

           53|     mkdir -p "$out/etc"
           54|     ${concatMapStringsSep "\n" (etcEntry: escapeShellArgs [
             |                                           ^
           55|       "makeEtcEntry"while calling 'concatMapStringsSep'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/strings.nix:116:5:

          115|     # List of input strings
          116|     list: concatStringsSep sep (map f list);
             |     ^
          117|

       … while calling 'escapeShellArg'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/strings.nix:454:20:

          453|   */
          454|   escapeShellArg = arg: "'${replaceStrings ["'"] ["'\\''"] (toString arg)}'";
             |                    ^
          455|

       … while calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:1205:18:

         1204|         mapAttrs
         1205|           (name: value:
             |                  ^
         1206|             if isAttrs value && cond valuefrom call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/attrsets.nix:1208:18:

         1207|             then recurse (path ++ [ name ]) value
         1208|             else f (path ++ [ name ]) value);
             |                  ^
         1209|     inwhile calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:242:72:

          241|           # For definitions that have an associated option
          242|           declaredConfig = mapAttrsRecursiveCond (v: ! isOption v) (_: v: v.value) options;
             |                                                                        ^
          243|

       … while evaluating the option `environment.etc.dbus-1.source':

       … while calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:846:17:

          845|       if isDefined then
          846|         if all (def: type.check def.value) defsFinal then type.merge loc defsFinal
             |                 ^
          847|         else let allInvalid = filter (def: ! type.check def.value) defsFinal;from call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:846:22:

          845|       if isDefined then
          846|         if all (def: type.check def.value) defsFinal then type.merge loc defsFinal
             |                      ^
          847|         else let allInvalid = filter (def: ! type.check def.value) defsFinal;while calling 'check'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/types.nix:535:15:

          534|       descriptionClass = "noun";
          535|       check = x: isStringLike x && builtins.substring 0 1 (toString x) == "/";
             |               ^
          536|       merge = mergeEqualOption;while evaluating derivation 'dbus-1'
         whose name attribute is located at /nix/store/lawcvljh83j9xdl2kkiqa9yy73lf3y3k-nixos-24.05/nixos/pkgs/stdenv/generic/make-derivation.nix:331:7while evaluating attribute 'serviceDirectories' of derivation 'dbus-1'

         at /nix/store/lawcvljh83j9xdl2kkiqa9yy73lf3y3k-nixos-24.05/nixos/pkgs/development/libraries/dbus/make-dbus-conf.nix:18:12:

           17|   {
           18|     inherit serviceDirectories suidHelper apparmor;
             |            ^
           19|     preferLocalBuild = true;while calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/types.nix:553:14:

          552|       merge = loc: defs:
          553|         map (x: x.value) (filter (x: x ? value) (concatLists (imap1 (n: def:
             |              ^
          554|           imap1 (m: def':

       … while calling anonymous lambda

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:846:17:

          845|       if isDefined then
          846|         if all (def: type.check def.value) defsFinal then type.merge loc defsFinal
             |                 ^
          847|         else let allInvalid = filter (def: ! type.check def.value) defsFinal;from call site

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/modules.nix:846:22:

          845|       if isDefined then
          846|         if all (def: type.check def.value) defsFinal then type.merge loc defsFinal
             |                      ^
          847|         else let allInvalid = filter (def: ! type.check def.value) defsFinal;while calling 'check'

         at /nix/var/nix/profiles/per-user/root/channels/nixos/lib/types.nix:535:15:

          534|       descriptionClass = "noun";
          535|       check = x: isStringLike x && builtins.substring 0 1 (toString x) == "/";
             |               ^
          536|       merge = mergeEqualOption;while evaluating derivation 'system-path'
         whose name attribute is located at /nix/store/lawcvljh83j9xdl2kkiqa9yy73lf3y3k-nixos-24.05/nixos/pkgs/stdenv/generic/make-derivation.nix:331:7while evaluating attribute 'passAsFile' of derivation 'system-path'

         at /nix/store/lawcvljh83j9xdl2kkiqa9yy73lf3y3k-nixos-24.05/nixos/pkgs/build-support/trivial-builders/default.nix:69:9:

           68|         inherit buildCommand name;
           69|         passAsFile = [ "buildCommand" ]
             |         ^
           70|           ++ (derivationArgs.passAsFile or [ ]);while evaluating derivation 'neovim-unwrapped-nightly'
         whose name attribute is located at /nix/store/lawcvljh83j9xdl2kkiqa9yy73lf3y3k-nixos-24.05/nixos/pkgs/stdenv/generic/make-derivation.nix:331:7while evaluating attribute 'preConfigure' of derivation 'neovim-unwrapped-nightly'

         at /nix/store/xrr5wy2jdcy8wh36jyazgx5kmzzliznc-source/flake/packages/neovim.nix:97:5:

           96|     inherit src;
           97|     preConfigure = ''
             |     ^
           98|       ${oa.preConfigure}

       … while calling anonymous lambda

         at /nix/store/lawcvljh83j9xdl2kkiqa9yy73lf3y3k-nixos-24.05/nixos/lib/attrsets.nix:1096:10:

         1095|     attrs:
         1096|     map (name: f name attrs.${name}) (attrNames attrs);
             |          ^
         1097|

       … from call site

         at /nix/store/lawcvljh83j9xdl2kkiqa9yy73lf3y3k-nixos-24.05/nixos/lib/attrsets.nix:1096:16:

         1095|     attrs:
         1096|     map (name: f name attrs.${name}) (attrNames attrs);
             |                ^
         1097|

       … while calling anonymous lambda

         at /nix/store/lawcvljh83j9xdl2kkiqa9yy73lf3y3k-nixos-24.05/nixos/pkgs/by-name/ne/neovim-unwrapped/package.nix:172:18:

          171|     '' + lib.concatStrings (lib.mapAttrsToList
          172|       (language: src: ''
             |                  ^
          173|         ln -s \

       … while evaluating derivation 'bash-grammar-neovim-nightly'
         whose name attribute is located at /nix/store/lawcvljh83j9xdl2kkiqa9yy73lf3y3k-nixos-24.05/nixos/pkgs/stdenv/generic/make-derivation.nix:331:7

       … while evaluating attribute 'src' of derivation 'bash-grammar-neovim-nightly'

         at /nix/store/lawcvljh83j9xdl2kkiqa9yy73lf3y3k-nixos-24.05/nixos/pkgs/by-name/ne/neovim-unwrapped/package.nix:175:20:

          174|           ${tree-sitter.buildGrammar {
          175|             inherit language src;
             |                    ^
          176|             version = "neovim-${finalAttrs.version}";

       error: cannot coerce a set to a string

well, treesitter did it

Edit: any suggestions on any other way of installing latest nightly build?
because, v0.9.5 won't cut it, some plugins (trouble and others) don't work, plus a load of random error messages popups

@willruggiano
Copy link
Contributor

That's the exact error because of #533. That issue applies to both flake usage, as demonstrated by the first code block in that issue, as well as overlay usage, as demonstrated by the second block. You are using the overlay and your code is identical to that of the second code block in the aforementioned issue.

So, my advice to you is the same as the advice in #533: upgrade your system's nixpkgs.

I'm not sure of the exact procedure for you, but if you share more about how you've installed nix I am happy to help debug with you.

@TeleVoyant
Copy link
Author

I'm not sure of the exact procedure for you, but if you share more about how you've installed nix I am happy to help debug with you.

Okay. This is a fresh installation of nixos 24.05 Uakari

here is a peek (configs related to pkgs) of file configuration.nix:

{ config, pkgs, ... }:

{
  # nix settings
  #nix.settings.experimental-features = [ "nix-command" "flakes" ];

  # save each configuration file under generation dir
  system.copySystemConfiguration = true;

  # nix packages extra configurations
  nixpkgs.config = {
    # Allow unfree packages
    allowUnfree = true;

    #Allow Old unmainttained
    #allowBroken = true;

    # Accept Nvidia license
    nvidia.acceptLicense = true;

    # Accept virtualbox license
    virtualbox.acceptLicense = true;

    #permitted insecure packages
    permittedInsecurePackages = [
      #"qtwebkit-5.212.0-alpha4"
      #"electron-25.9.0"
    ];
  };
  #################################


  # List of Overlays, containing configuration for installing neovim's nightly packages
  nixpkgs.overlays = [
    (import (builtins.fetchTarball {
      url = "https://github.com/nix-community/neovim-nightly-overlay/archive/master.tar.gz";
    }))
  ];


  # List packages installed in system profile. To search, run:
  # $ nix search wget
  environment.systemPackages = with pkgs; [
    #  vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
    #  wget

    # nixos core packages
    nixos-option # extra options
    cachix # cache

    # dev env
    #neovim-nightly # TUI: 1st favourite editor (nightly builds)
    neovim # TUI: 1st favourite editor
    zed-editor # High-performance, multiplayer code editor
    geany # small, lightweight IDE
    fzf # TUI: fuzzy finder written in Go
    fzf-git-sh # TUI: key bindings for Git objects, powered by fzf.
    fd # TUI: simple, fast and user-friendly alternative to find
    bat # TUI: cat clone with wings.
    delta # TUI: diff, grep, and blame output for git
    eza # TUI: modern, maintained replacement for ls 
    unixtools.xxd # hex-editor
    wl-clipboard # cli clipboard manager
    tmux # terminal multiplexer
    nerdfonts # for programming
    git # version control
    gh # git user manager
    androidStudioPackages.canary
    wxhexeditor # advanced HEX editor
    insomnia # API DevTest
    libvirt # toolkit to interact with the virtualization
    virtualbox # GUI virtualizer
    qemu_full # machine emulator and CLI virtualizer
    #ciscoPacketTracer8

  ];

}

Any suggestion will be highly appreciated :)

@metiulekm
Copy link

It seems that the nixpkgs changes this repo depends on did not reach NixOS 24.05 at all. The most recent neovim-unwrapped commit on that branch is NixOS/nixpkgs@76ef4c7, which actually reverts those changes. I had a similar issue when attempting to move my config from unstable to 24.05.

Maybe a separate branch for 24.05 would be needed if this repo is supposed to support it?

@TeleVoyant
Copy link
Author

Maybe a separate branch for 24.05 would be needed if this repo is supposed to support it?

Agreed. This might just be a better approach to the problem, a "versioning" under the hood.

@willruggiano
Copy link
Contributor

willruggiano commented Jun 7, 2024

I'm not going to cut a 24.05 branch. This is the only issue we've had regarding 24.05. You can just as easily work around it yourself by adding a different channel, e.g. nixpkgs-unstable, and cherry picking packages out of that package set, e.g.

nixpkgs.config = {
  packageOverrides = pkgs: let
    pkgs' = import <nixpkgs-unstable> {
      inherit (pkgs) system;
      overlays = [
        (import (builtins.fetchTarball {
          url = "https://github.com/nix-community/neovim-nightly-overlay/archive/master.tar.gz";
        }))
      ];
    };
  in {
    inherit (pkgs') neovim;
  };
};

(no promises this compiles as is, wrote it off the top of my head)

You could convert your configuration.nix to Flakes (which I would suggest you do considering it is a "fresh installation" and so shouldn't be overly complicated). You can probably directly import your configuration.nix as part of your nixosSystem call;

{
  inputs = {
    nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05";
    neovim-nightly.url = "github:nix-community/neovim-nightly-overlay";
  };

  outputs = {
    self,
    nixpkgs,
    ...
  } @ inputs: {
    nixosConfigurations.YOUR_SYSTEM = nixpkgs.lib.nixosSystem rec {
      system = "x86_64-linux";
      modules = [
        ./configuration.nix
        {
          environment.systemPackages = [
            inputs.neovim-nightly.packages.${system}.default
          ];
        }
      ];
    };
  };
}

(again, no promises this compiles)

@willruggiano willruggiano closed this as not planned Won't fix, can't repro, duplicate, stale Jun 15, 2024
@willruggiano
Copy link
Contributor

Closing this but feel free to open a new issue if you need help

@TeleVoyant
Copy link
Author

i have no solution to this problem yet @willruggiano

@willruggiano
Copy link
Contributor

willruggiano commented Jun 16, 2024

There are two solutions above. Have you tried either of them?

@TeleVoyant
Copy link
Author

TeleVoyant commented Jun 18, 2024

(no promises this compiles as is, wrote it off the top of my head)

this does not strike confidence to try it sir...

i will try it out.

@willruggiano willruggiano changed the title Neovim-nightly fails to fetch nightly builds Can't use nightly overlay with NixOS 24.05 Jun 18, 2024
@TeleVoyant
Copy link
Author

TeleVoyant commented Jun 18, 2024

It worked.
add the segment below to your configuration.nix

nixpkgs.config = {
  packageOverrides = pkgs: let
    pkgs' = import <nixpkgs-unstable> {
      inherit (pkgs) system;
      overlays = [
        (import (builtins.fetchTarball {
          url = "https://github.com/nix-community/neovim-nightly-overlay/archive/master.tar.gz";
        }))
      ];
    };
  in {
    inherit (pkgs') neovim;
  };
};

then run this on the terminal

sudo nix-channel --add https://nixos.org/channels/nixos-unstable nixpkgs-unstable

emphasis on nixpkgs-unstable, should be the same as <nixpkgs-unstable> from above segment

PostScript:
Thank you for your time @willruggiano
To spin up code segment that immediately runs is no easy feat.
you are amaizing :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants