Release 2.18 (2023-09-20)
-
Two new builtin functions,
builtins.parseFlakeRefandbuiltins.flakeRefToString, have been added. These functions are useful for converting between flake references encoded as attribute sets and URLs. -
builtins.toJSONnow prints --show-trace items for the path in which it finds an evaluation error. -
Error messages regarding malformed input to
nix derivation addare now clearer and more detailed. -
The
discard-referencesfeature has been stabilized. This means that theunsafeDiscardReferencesattribute is no longer guarded by an experimental flag and can be used freely. -
The JSON output for derived paths which are store paths is now a string, not an object with a single
pathfield. This only affectsnix-build --jsonwhen "building" non-derivation things like fetched sources, which is a no-op. -
A new builtin
outputOfhas been added. It is part of thedynamic-derivationsexperimental feature. -
Flake follow paths at depths greater than 2 are now handled correctly, preventing "follows a non-existent input" errors.
-
nix-store --querygained a new type of query:--valid-derivers. It returns all.drvfiles in the local store that can be used to build the output passed in argument. This is in contrast to--deriver, which returns the single.drvfile that was actually used to build the output passed in argument. In case the output was substituted from a binary cache, this.drvfile may only exist on said binary cache and not locally.