in src/nix/hive/options.nix
you should add
aliases = lib.mkOption {
description = ''
A list of aliases for the node.
Can be used to select a node with another name.
…
Forgot to write the final comment: it just need to make aliases
optional, to avoid the error
error:
… while evaluating attribute 'ap01'
… while evaluating attribute…
I don't think it's necessary to change this, this over-engineering won't weight much and will make future development cleaner (if the invariant was invalidated for example).
(In syntactic analysis, !a&a
is trivial, but require a semantic analysis, which I don't think we want)
Currently, the only trivial filter is Empty
as it's not possible to build trivial Union
or Inter
(trivial = size < 2), nor to have an Empty
in a leaf of a more complex filter.
This assert fails in the case of empty filter (which should matches all nodes)
It feels weird that we allow a node to have an alias being the name of another, like a
and b
, with b.aliases = [ "a" ]
, in which case colmena apply --on a
applies both nodes. Idk if we…
missing space between the 2 {}
in inherit (attrs) {}{};
(when both are required).