[Nix-dev] NixOS module assertions

Ludovic Courtès ludo at gnu.org
Mon Mar 28 17:33:34 CEST 2011


Hello,

Currently setting ‘boot.kernelPackages = linuxPackages_2_6_34;’ results
in the oh-so-clear error message below:

  value is null while an attribute set was expected

The reason is that ‘linuxPackages_2_6_34’ doesn’t have the fbcondecor
patch, and thus ‘kernelPackages.splashutils’ is null.
‘tty-backgrounds.nix’ then references ‘splashutils’, hence the error.

There’s an assertion in ‘tty-backgrounds.nix’, which checks whether
‘splashutils’ is null.  However, that assertion is apparently not
checked by the time ‘splashutils’ is referenced in ‘preStart’ and
‘postStop’.

Why is that?  How should we work around it?

Thanks,
Ludo’.




More information about the nix-dev mailing list