Files
lix/doc/manual/rl-next/check-warn-about-missing-paths.md
T
Raito Bezarius e9cccd47e2 libstore/build: report better error messages for --check
When --check is ran with no output, this is seen as having *SOME*
invalid outputs, actually, ALL of them are invalid here.

Instead of reporting a confusing error, let's consider ALL of outputs
being invalid to be no output at all available and advise the user to
rerun the build without --check.

If there's *some* (>0) invalid outputs, let's print them exactly to give
a chance to the user to remediate this.

Fixes #485.

Change-Id: I00955ef9ea4f129e2c98d68c73b1e981f90278a0
Signed-off-by: Raito Bezarius <raito@lix.systems>
2026-01-10 12:42:50 +01:00

1.1 KiB

synopsis, cls, issues, category, credits
synopsis cls issues category credits
`--check` or `--rebuild` is clearer about a missing path
fj#485
Improvements
raito

Previously, when running Lix with --check or --rebuild, failures often surfaced as an unhelpful error:

"some outputs of '...' are not valid, so checking is not possible"

This message could mean two different things:

  • The requested output paths don't exist at all, or,
  • Some outputs exist but are not known to Lix

Lix cannot reliably distinguish these cases, so it treated them the same.

We've updated the error messages to clarify what Lix can determine: whether any valid outputs (> 0) are present or whether no outputs are available.

When no valid outputs can be found, Lix will now suggest building the derivation normally (without --check or --rebuild) before trying again.

When some valid outputs are present, Lix now reports which ones are valid, shows the full list of known outputs, and also suggests building the derivation normally.

In the future, Lix may automate this recovery step when it knows how to rebuild the paths, but implementing that safely requires more extensive changes to the codebase.