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

feat(error): add Error::message #2737

Merged
merged 2 commits into from
Feb 5, 2022
Merged

feat(error): add Error::message #2737

merged 2 commits into from
Feb 5, 2022

Conversation

davidpdrsn
Copy link
Member

@davidpdrsn davidpdrsn commented Jan 18, 2022

This is an alternate solution to #2732 that doesn't change hyper::Error's Display impl (like #2542 does).

It adds Error::message which returns the message that is unique to the error, without the message from the source. That way users can create a newtype around hyper::Error and use this in the Display impl to work around #2732.

Fixes #2732

@seanmonstar seanmonstar merged commit 6932896 into master Feb 5, 2022
@seanmonstar seanmonstar deleted the david/error-message branch February 5, 2022 01:10
@davidpdrsn
Copy link
Member Author

@seanmonstar any chance you wanna cut a release with this?

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

Successfully merging this pull request may close these issues.

hyper::Error should either print source in display xor return a Some from Error::cause(), not both
3 participants