It appears to me that you do not raise your own exceptions in the APIs, but instead just the built-in Exception, or just propagate the ConnectionError exception from requests.
Take geckoboard-python/geckoboard/datasets_client.py for example:
def find_or_create(self, dataset_id, fields, unique_by=None):
"""
Creates a new, or returns an existing dataset
Searches for a dataset with a matching ID and schema. If a
match is found that dataset is returned. Otherwise, a new
dataset is created and returned.
The dataset instance that is returned allows you
to update or delete that dataset.
...
Raises
------
Exception
If your API key is invalid or an existing dataset is found
with a schema that doesn't match the one provided
ConnectionError
If you could not connect to the Geckoboard API
"""
This makes exception handling difficult for your users, as we are not able to handle exceptions specifically related to Geckoboard connections while other things can go wrong in the same try...except block.
It appears to me that you do not raise your own exceptions in the APIs, but instead just the built-in
Exception, or just propagate theConnectionErrorexception fromrequests.Take
geckoboard-python/geckoboard/datasets_client.pyfor example:This makes exception handling difficult for your users, as we are not able to handle exceptions specifically related to Geckoboard connections while other things can go wrong in the same
try...exceptblock.