Review api error handling
dinoboff opened this issue · 2 comments
dinoboff commented
Since odyssey, failed api call return a 4xx or 5xx code. Those http codes raise exception in API.send_request.
As a result, the error element in a failed responses are never parsed; APIError exceptions are never raised and failed request are never cached.
ayust commented
Do you know offhand if this is the case for both the urllib2
and requests
paths, or just one of them? (IIRC, requests
normally doesn't raise exceptions by default, it still returns a Response
object.)