-
Notifications
You must be signed in to change notification settings - Fork 319
switch Method and StatusCode to http-types
#860
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
Conversation
This reverts commit acf6eda.
| error_code = error_code.or_else(|| get_error_code_from_body(&body)); | ||
| HttpError { | ||
| status: status.as_u16(), | ||
| status: status as u16, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since we are re-exporting StatusCode now, can we make the error include the enum value instead of a u16? This will make dealing with contextualized errors significantly more straightforward.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that is a good idea in a separate PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added #870
This reverts commit b645f76.
yoshuawuyts
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
http-typeshas better representations of bothMethodandStatusCodeas I described in more detail earlier.I reverted the generated services code to make it easier to review.