Expand description
Helpers for error handling.
Traits§
- Loggable
Error - A trait that allows printing the entire error chain of an Error (it is implemented for
anyhow::Error) along with a custom context message. - Pretty
Unwrap - A trait to provide a nicer way to unwarp
anyhow::Result.
Functions§
- display_
error - Displays an
anyhow::Error’s main error and its error chain to stderr. - into_
io_ error - Generates an
io::Errorfrom the givenanyhow::Error. - io_
error - Generates an
io::Errorfrom the given string. - log_
error - Logs
anyhow::Error’s its error chain using theERRORlog level. - log_
warning - Logs
anyhow::Error’s its error chain using theWARNlog level.