Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Option to print error with causes multiline but no backtrace #300

Open
stepancheg opened this issue Mar 17, 2023 · 0 comments
Open

Option to print error with causes multiline but no backtrace #300

stepancheg opened this issue Mar 17, 2023 · 0 comments

Comments

@stepancheg
Copy link
Contributor

There are for options to print anyhow::Error:

  • only the message {}
  • single line causes {:#}
  • causes and backtrace {:?}
  • debug {:#?}

There's no way to print causes in multiple lines and no backtrace.

Possible API:

impl Error {
  /// Multiline display: output the message, the causes, but no backtrace even if captured.
  pub fn display_no_backtrace(&self) -> impl Display { ... }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant