runzero.errors#

errors is a package-wide container for the bottom-level custom error types used in this package.

Some errors here may originate from the server. In these cases, we want to make the raw server error details available, but hidden from plain view you can concentrate on what to do in response instead of interpreting HTTP error codes.

Other errors arise from purely local interactions.

In either case, Error should be the base type if it’s an error deliberately raised in this package.

Sub-packages and modules may create their own error types in those packages, particularly if they are not useful outside of that package, but should inherit a base type here.

Module Contents#

exception runzero.errors.APIError[source]#

Bases: Error

APIError is a named Exception class representing errors which are returned from runZero API endpoints.

Initialize self. See help(type(self)) for accurate signature.

with_traceback()#

Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.

exception runzero.errors.Error[source]#

Bases: Exception

Error is a named Exception class representing bottom-level runZero Error type.

It is not to be raised directly, but callers can catch it and distinguish runZero errors from any others.

Initialize self. See help(type(self)) for accurate signature.

with_traceback()#

Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.