Repository navigation
Replies: 2 comments 1 reply
|
The formatter prints one error message. It does not walk For a value-validation failure it writes your error's Include the inner text in the message you want on the command line: #[error("parsing coordinate for {field}: {source}")]Clap will then print both, because both are in that one |
1 reply
|
Error chains don't quite align with the styling of clap's error messages As an aside, I find it sad that Rust's error handling ecosystem hasn't evolved past error chains because they are are terrible way of adding context for the end user. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
clap's error formatting doesn't seem to walk the custom parser's (implemented with
std::str::FromStr) error's source chain, so the error gets cut off at the first error's message and doesn't provide the full context for it. Is this intended behavior?clap/clap_builder/src/error/format.rs
Lines 313 to 332 in 4be5613
All reactions