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

[DAR-3984][External] Improved HTTP error code verbosity #927

Merged
merged 1 commit into from
Sep 17, 2024
Merged

Conversation

JBWilkie
Copy link
Collaborator

Problem

Whenever darwin-py makes an API call, it raises various exceptions in the raise_for_darwin_exception() function if the response object has an error code that needs to be raised. However, it simply raises the object itself which shows only the error code. It would be very helpful (especially for 422s) if the error text was also displayed

Solution

Display response.text as well as response when raising HTTP error codes

Changelog

Increased detail of error handling in darwin-py

Copy link

linear bot commented Sep 17, 2024

@JBWilkie JBWilkie merged commit 4e9435d into master Sep 17, 2024
20 checks passed
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