Exceptions¶
PyOWM uses custom exception classes. Here you can learn which classes are used and when such exceptions are cast by the library
Exceptions Hierarchy¶
Exception
|
|___PyOWMError
|
|___ConfigurationError
| |
| |__ConfigurationNotFoundError
| |__ConfigurationParseError
|
|___APIRequestError
| |
| |__BadGatewayError
| |__TimeoutError
| |__InvalidSSLCertificateError
|
|___APIResponseError
|
|__NotFoundError
|__UnauthorizedError
|__ParseAPIResponseError
Exception root causes¶
PyOWMError
is the base class. Never raised directlyConfigurationError
parent class for configuration-related exceptions. Never raised directlyConfigurationNotFoundError
raised when trying to load configuration from a non-existent fileConfigurationParseError
raised when configuration can be loaded from the file but is in a wrong, unparsable formatAPIRequestError
base class for network/infrastructural issues when invoking OWM APIsBadGatewayError
raised when upstream OWM API backends suffer communication issues.TimeoutError
raised when calls to the API suffer timeout due to slow response times upstreamInvalidSSLCertificateError
raised when it is impossible to verify the SSL certificates provided by the OWM APIsAPIResponseError
base class for non-ok API responses from OWM APIsNotFoundError
raised when the user tries to access resources that do not exist on the OWM APIsUnauthorizedError
raised when the user tries to access resources she is not authorized to access (eg. you need a paid API subscription)ParseAPIResponseError
raised upon impossibility to parse the JSON payload of API responses