You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This leads to the Display representation being quite large in some cases. I think a better approach is to include the source in Error::source so its up to users how much information they want to show.
The text was updated successfully, but these errors were encountered:
At Embark we have a little helper function that converts a `&dyn
std::error::Error` into a `String` by walking the full chain of sources
(with `std::error::Error::source`) and joining them into a `String`.
We use that where we log errors to get as much information as possible
about whats causing an error. Works particularly well with anyhow's
`.context()` method.
However since `tonic::transport::Error` include its cause in their
`Display` impl we get the sources more than once.
As the cause can already be obtained through `std::error::Error::source`
no information should be lost by doing this.
Fixes#632
At Embark we have a little helper function that converts a `&dyn
std::error::Error` into a `String` by walking the full chain of sources
(with `std::error::Error::source`) and joining them into a `String`.
We use that where we log errors to get as much information as possible
about whats causing an error. Works particularly well with anyhow's
`.context()` method.
However since `tonic::transport::Error` include its cause in their
`Display` impl we get the sources more than once.
As the cause can already be obtained through `std::error::Error::source`
no information should be lost by doing this.
Fixes#632
This leads to the
Display
representation being quite large in some cases. I think a better approach is to include the source inError::source
so its up to users how much information they want to show.The text was updated successfully, but these errors were encountered: