nix
nix copied to clipboard
nix build --keep-going doesn't report what failed
Describe the bug
When using --keep-going, nix reports build failures as they come. At the end, it only reports the number of packages that failed, but not their names. The names will be hidden in log history.
Steps To Reproduce
with import <nixpkgs> {}; let
mkFailing = name:
pkgs.runCommandLocal name {} ''
exit 1
'';
in
linkFarmFromDrvs "farm" [
(mkFailing "drv-a")
(mkFailing "drv-b")
(mkFailing "drv-c")
(runCommandLocal "many-logs" {} ''
for i in $(seq 1 10); do
echo ":: doing stuff"
done
touch $out
'')
]
$ nix build -f ./test.nix --keep-going -L
error: builder for '/nix/store/pyh081a8vvhcar6m2qip5q3i8gzqinm6-drv-a.drv' failed with exit code 1
error: builder for '/nix/store/6mbsj7b18ww8mr21ac8k5jnhd65lravh-drv-b.drv' failed with exit code 1
error: builder for '/nix/store/jyz83cbvqni6ck8j06rpd9zg1j0hfnb0-drv-c.drv' failed with exit code 1
many-logs> :: doing stuff
many-logs> :: doing stuff
many-logs> :: doing stuff
many-logs> :: doing stuff
many-logs> :: doing stuff
many-logs> :: doing stuff
many-logs> :: doing stuff
many-logs> :: doing stuff
many-logs> :: doing stuff
many-logs> :: doing stuff
error: 3 dependencies of derivation '/nix/store/jx7wa9qv6dkqb1kjwvmhwqpn4syd9q3j-farm.drv' failed to build
Expected behavior
This report is generated by nix-output-monitor, so I would expect something similar:
┃ ├─ ⚠ drv-a failed with exit code 1 after ⏱ 0s
┃ ├─ ⚠ drv-c failed with exit code 1 after ⏱ 0s
┃ ├─ ⚠ drv-b failed with exit code 1 after ⏱ 0s
Additional context
Priorities
Add :+1: to issues you find important.
Shouldn't this do the job? https://github.com/NixOS/nix/pull/10734 (it's in 2.24)
Could you try if that's the case?
hmm, output looks the same, sorry maybe that's just for FODs.