fathomnet / fathomnet-py

FathomNet Python client
https://fathomnet-py.readthedocs.io
MIT License
24 stars 3 forks source link

Improve error message on non-200 HTTP response status code #16

Closed kevinsbarnard closed 1 year ago

kevinsbarnard commented 1 year ago

Currently, the handling when a non-200 status code is encountered in an HTTP response is pretty poor. Generated exceptions are not all that helpful, e.g.:

ValueError: Bad request: http://fathomnet.org:8080/images/query

It would be nice to have a more helpful error message.

Originated from #15