Closed simon-contreras-deel closed 5 years ago
(This issue should be created in the pyrestcli repo, but we are not managing it right now)
pyrestcli
We are managing responses in different ways, catching some exception and passing others:
We have 3 different approaches (at least) to manage responses, it could be reasonable but at least, there are problems and bugs managing errors, because the idea is to manage errors using:
get_response_data
but sometimes we are not using it (the client should do it explicitly if you are using the Manager for example) and in some cases, we are managing other cases here like CartoRateLimitException https://github.com/CartoDB/carto-python/blob/master/carto/auth.py#L151-L152
CartoRateLimitException
I don't want to write the solution here, at least I am going to say we should have a unique place where:
Related issue: https://github.com/CartoDB/carto-python/issues/112
(This issue should be created in the
pyrestcli
repo, but we are not managing it right now)We are managing responses in different ways, catching some exception and passing others:
We have 3 different approaches (at least) to manage responses, it could be reasonable but at least, there are problems and bugs managing errors, because the idea is to manage errors using:
get_response_data
https://github.com/danicarrion/pyrestcli/blob/master/pyrestcli/auth.py#L38-L62but sometimes we are not using it (the client should do it explicitly if you are using the Manager for example) and in some cases, we are managing other cases here like
CartoRateLimitException
https://github.com/CartoDB/carto-python/blob/master/carto/auth.py#L151-L152I don't want to write the solution here, at least I am going to say we should have a unique place where:
get_response_data
is doing right now)Related issue: https://github.com/CartoDB/carto-python/issues/112