ohsu-comp-bio / py-tes

Python SDK for the GA4GH Task Execution API
https://py-tes.readthedocs.io/
MIT License
5 stars 10 forks source link

Simplifying the raise for status pattern #36

Closed kellrott closed 3 years ago

kellrott commented 3 years ago

Now call failure will throw original HTTPError exception, rather then creating a new one. The response should still be available ( see https://docs.python-requests.org/en/master/_modules/requests/exceptions/ )

adamnovak commented 3 years ago

OK, I tested this, and it seems to work. e.response.status_code is there, even though e.response is falsey (which I think is just Requests' design decision).