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

Error patches #63

Merged
merged 13 commits into from
Jan 23, 2020
Merged

Error patches #63

merged 13 commits into from
Jan 23, 2020

Conversation

yoshuawuyts
Copy link
Member

@yoshuawuyts yoshuawuyts commented Jan 19, 2020

This updates the Error and ErrorKind types to contain a StatusCode field that can be used to set a status code. This will help us make progress on:

Additionally we can now cast any Error + Send + Sync to an http_types::Error, with support for downcasting and traversing error chains.

Changes

  • Polishes Error and ErrorKind
  • Replaces all placeholder instances of io::Error with http_types::Error

Todos

  • fix tests
  • remove todo!s
  • replace ParseError types
  • add bail!, ensure! and format_err! macros

Addresses the last of @dignifiedquire's comments; this should be enough to pass the review!
Copy link
Member

@dignifiedquire dignifiedquire left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👌

@yoshuawuyts yoshuawuyts merged commit aebbfd9 into master Jan 23, 2020
@delete-merged-branch delete-merged-branch bot deleted the error-patches branch January 23, 2020 11:15
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.

2 participants