Two problems with a cargo build that produces no binary, which happens
for a library-only crate or for an argument like --help that stops it
building at all.
The driver threw, which surfaced to the user as a 400 carrying "Cannot
read properties of undefined (reading 'optPath')" -- handleUserError
returns a result with no inner `result`, which afterCompilation then
reads straight through. The message never reached the UI at all. That is
not an error condition anyway, so finaliseArtifact now returns an
explanation instead of throwing, and the orchestrator reports it the
same way it reports a failed build step: a properly shaped result whose
assembly pane says why there is nothing to show, with a code of 0
because nothing actually went wrong.
The driver also blanked the whole of cargo's stdout to hide the JSON
records it had asked for. `cargo build --help` prints its help there, so
that output -- the entire point of the request -- was being thrown away.
It now drops only the lines that parse as records and keeps the rest.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>