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

[REQ] [Go] Improved error message when model implements RFC7807 #13679

Closed
gcatanese opened this issue Oct 12, 2022 · 0 comments · Fixed by #13680
Closed

[REQ] [Go] Improved error message when model implements RFC7807 #13679

gcatanese opened this issue Oct 12, 2022 · 0 comments · Fixed by #13680

Comments

@gcatanese
Copy link
Contributor

Is your feature request related to a problem? Please describe.

When the API call returns an error (3xx, 4xx, 5xx) the generated Go client returns the GenericOpenAPIError with body, error and model of the returned errors. The error attribute includes the HTTP Status Code (ie 422).

Describe the solution you'd like

When the problem error JSON implements RFC7807 it would be much better to include Title and Detail so that the underlying cause of the error is immediately visible.

Describe alternatives you've considered

When logging the error only the status code is available. At the moment the client application needs to parse/decode the full HTTP response to have a better understanding of the cause of the error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant