tchellomello / python-amcrest

A Python 2.7/3.x module for Amcrest and Dahua Cameras using the SDK HTTP API.
GNU General Public License v2.0
213 stars 76 forks source link

Change caught httpx error type #208

Closed flacjacket closed 2 years ago

flacjacket commented 2 years ago

Change to catch the top level httpx exception. The current exception type will catch some request errors (eg timeouts) but will not catch http status errors (eg 500 errors). Changing the error type here will allow users to more easily handle spurious errors of this type.