coinbase / coinbase-python

DEPRECATED — Coinbase Python API
Apache License 2.0
528 stars 217 forks source link

Handle 502 HTTP error codes and absent JSON #86

Closed JohnLZeller closed 5 years ago

JohnLZeller commented 5 years ago

This fixes #44.

Contrary to what #44 suggests, there is actually solid error handling in this package, but 502 was absent from these handlers. We also were not handling the situation where there is not a decodable json attached to the response object. This PR defaults to grabbing the response.content instead, when json data is not present.

sds commented 5 years ago

Thanks!