xyzspaces.iml.exceptions module

This module defines all the exceptions for iml package.

exception xyzspaces.iml.exceptions.AuthenticationException(resp)[source]

Bases: Exception

This AuthenticationException is raised either authentication or authorization on the platform fails.

__init__(resp)[source]

Instantiate AuthenticationException . :param resp: response detail will be stored in this param

__str__()[source]

Return the message to be raised for this exception.

Returns

error message

Return type

str

exception xyzspaces.iml.exceptions.TooManyRequestsException(resp)[source]

Bases: Exception

Exception raised for API HTTP response status code 429.

This is a dedicated exception to be used with the backoff package, because it requires a specific exception class. The exception value will be the response object returned by requests which provides access to all its attributes, eg. status_code, reason and text, etc.

__init__(resp)[source]

Instantiate AuthenticationException . :param resp: response detail will be stored in this param

__str__()[source]

Return a string from the HTTP response causing the exception.

The string simply lists the response status code, reason and text content, separated with commas.

exception xyzspaces.iml.exceptions.ConfigException[source]

Bases: Exception

This ConfigException is raised whenever there is any error related to platform configuration.

exception xyzspaces.iml.exceptions.PayloadTooLargeException(resp)[source]

Bases: Exception

Exception raised for API HTTP response status code 513.

This is a dedicated exception to be used for interactive map layer. This exception will be raised when response payload is larger than the specified limits of the interactive map layer. The exception value will be the response object returned by requests which provides access to all its attributes, eg. status_code, reason and text, etc.

__init__(resp)[source]

Instantiate AuthenticationException . :param resp: response detail will be stored in this param

__str__()[source]

Return a string from the HTTP response causing the exception.

The string simply lists the response status code, reason and text content, separated with commas.

exception xyzspaces.iml.exceptions.RequestEntityTooLargeException(resp)[source]

Bases: Exception

Exception raised for API HTTP response status code 413.

This is a dedicated exception to be used for interactive map layer. This exception will be raised when request body is larger than the specified limits of the interactive map layer. The exception value will be the response object returned by requests which provides access to all its attributes, eg. status_code, reason and text, etc.

__init__(resp)[source]

Instantiate AuthenticationException . :param resp: response detail will be stored in this param

__str__()[source]

Return a string from the HTTP response causing the exception.

The string simply lists the response status code, reason and text content, separated with commas.