fix(compile): show full error chain in batch compile output#411
Merged
Conversation
When compiling all pipelines, errors were printed with Display format ({})
which only showed the outermost anyhow context ('Failed to parse YAML
front matter'). The underlying serde error with the specific unknown field
name was swallowed.
Switch to alternate Display format ({:#}) which prints the full error
chain, so users see the specific parse failure (e.g. 'unknown field
\safeoutputs\, expected one of \
ame\, \description\, ...').
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
🔍 Rust PR ReviewSummary: Correct and minimal — no issues found. Findings✅ What Looks Good
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
When batch-compiling pipelines (
ado-aw compilewith no path), front matter parse errors only showed the outermost context message:The underlying serde error — which names the specific unknown field and lists valid alternatives — was swallowed by the
{}(Display) format.Fix
Switch from
{}to{:#}(alternate Display) foranyhow::Error, which prints the full error chain. Users now see:The single-file compile path (
ado-aw compile <file>) was already fine — its error propagates tomain()where Rust'sDebugformatting shows the full chain.Change
One-character change in
src/compile/mod.rs:{}→{:#}in the batch compile erroreprintln!.