weaver.exceptions

Errors raised during the weaver flow.

Module Contents

weaver.exceptions.LOGGER[source]
exception weaver.exceptions.WeaverException[source]

Bases: Exception

Base class of exceptions defined by weaver package.

exception weaver.exceptions.InvalidIdentifierValue[source]

Bases: weaver.exceptions.WeaverException, ValueError

Error indicating that an id to be employed for following operations is not considered as valid to allow further processed or usage.

exception weaver.exceptions.ServiceException[source]

Bases: weaver.exceptions.WeaverException

Base exception related to a weaver.datatype.Service.

exception weaver.exceptions.ServiceNotAccessible[source]

Bases: weaver.exceptions.ServiceException

Error indicating that a WPS service exists but is not visible to retrieve from the storage backend of an instance of weaver.store.ServiceStore.

exception weaver.exceptions.ServiceNotFound[source]

Bases: weaver.exceptions.ServiceException

Error indicating that an OWS service could not be read from the storage backend by an instance of weaver.store.ServiceStore.

exception weaver.exceptions.ServiceRegistrationError[source]

Bases: weaver.exceptions.ServiceException

Error indicating that an OWS service could not be registered in the storage backend by an instance of weaver.store.ServiceStore.

exception weaver.exceptions.ProcessException[source]

Bases: weaver.exceptions.WeaverException

Base exception related to a weaver.datatype.Process.

exception weaver.exceptions.ProcessNotAccessible[source]

Bases: weaver.exceptions.ProcessException

Error indicating that a local WPS process exists but is not visible to retrieve from the storage backend of an instance of weaver.store.ProcessStore.

exception weaver.exceptions.ProcessNotFound[source]

Bases: weaver.exceptions.ProcessException

Error indicating that a local WPS process could not be read from the storage backend by an instance of weaver.store.ProcessStore.

exception weaver.exceptions.ProcessRegistrationError[source]

Bases: weaver.exceptions.ProcessException

Error indicating that a WPS process could not be registered in the storage backend by an instance of weaver.store.ProcessStore.

exception weaver.exceptions.ProcessInstanceError[source]

Bases: weaver.exceptions.ProcessException

Error indicating that the process instance passed is not supported with storage backend by an instance of weaver.store.ProcessStore.

exception weaver.exceptions.JobException[source]

Bases: weaver.exceptions.WeaverException

Base exception related to a weaver.datatype.Job.

exception weaver.exceptions.JobNotFound[source]

Bases: weaver.exceptions.JobException

Error indicating that a job could not be read from the storage backend by an instance of weaver.store.JobStore.

exception weaver.exceptions.JobRegistrationError[source]

Bases: weaver.exceptions.JobException

Error indicating that a job could not be registered in the storage backend by an instance of weaver.store.JobStore.

exception weaver.exceptions.JobUpdateError[source]

Bases: weaver.exceptions.JobException

Error indicating that a job could not be updated in the storage backend by an instance of weaver.store.JobStore.

exception weaver.exceptions.PackageException[source]

Bases: weaver.exceptions.WeaverException

Base exception related to a weaver.processes.wps_package.Package.

exception weaver.exceptions.PackageTypeError[source]

Bases: weaver.exceptions.PackageException

Error indicating that an instance of weaver.processes.wps_package.Package could not properly parse input/output type(s) for package deployment or execution.

exception weaver.exceptions.PackageRegistrationError[source]

Bases: weaver.exceptions.PackageException

Error indicating that an instance of weaver.processes.wps_package.Package could not properly be registered for package deployment because of invalid prerequisite.

exception weaver.exceptions.PackageExecutionError[source]

Bases: weaver.exceptions.PackageException

Error indicating that an instance of weaver.processes.wps_package.Package could not properly execute the package using provided inputs and package definition.

exception weaver.exceptions.PackageNotFound[source]

Bases: weaver.exceptions.PackageException

Error indicating that an instance of weaver.processes.wps_package.Package could not properly retrieve the package definition using provided references.

exception weaver.exceptions.PayloadNotFound[source]

Bases: weaver.exceptions.PackageException

Error indicating that an instance of weaver.processes.wps_package.Package could not properly retrieve the package deploy payload using provided references.

exception weaver.exceptions.QuoteException[source]

Bases: weaver.exceptions.WeaverException

Base exception related to a weaver.datatype.Quote.

exception weaver.exceptions.QuoteNotFound[source]

Bases: weaver.exceptions.QuoteException

Error indicating that a quote could not be read from the storage backend by an instance of weaver.store.QuoteStore.

exception weaver.exceptions.QuoteRegistrationError[source]

Bases: weaver.exceptions.QuoteException

Error indicating that a quote could not be registered in the storage backend by an instance of weaver.store.QuoteStore.

exception weaver.exceptions.QuoteInstanceError[source]

Bases: weaver.exceptions.QuoteException

Error indicating that a given object doesn’t correspond to an expected instance of weaver.datatype.Quote.

exception weaver.exceptions.BillException[source]

Bases: weaver.exceptions.WeaverException

Base exception related to a weaver.datatype.Bill.

exception weaver.exceptions.BillNotFound[source]

Bases: weaver.exceptions.BillException

Error indicating that a bill could not be read from the storage backend by an instance of weaver.store.BillStore.

exception weaver.exceptions.BillRegistrationError[source]

Bases: weaver.exceptions.BillException

Error indicating that a bill could not be registered in the storage backend by an instance of weaver.store.BillStore.

exception weaver.exceptions.BillInstanceError[source]

Bases: weaver.exceptions.BillException

Error indicating that a given object doesn’t correspond to an expected instance of weaver.datatype.Bill.

weaver.exceptions.log_unhandled_exceptions(logger=LOGGER, message='Unhandled exception occurred.', exception=Exception, force=False, require_http=True, is_request=True) → Callable[source]

Decorator that will raise exception with specified message if an exception is caught while execution the wrapped function, after logging relevant details about the caught exception with logger.

Parameters:
  • logger – logger to use for logging (default: use weaver.exception.LOGGER).
  • message – message that will be logged with details and then raised with exception.
  • exception – exception type to be raised instead of the caught exception.
  • force – force handling of any raised exception (default: only known unhandled exceptions are logged).
  • require_http – consider non HTTP-like exceptions as unknown and raise one instead (default: True and raises HTTPInternalServerError, unless exception is HTTP-like).
  • is_request – specifies if the decorator is applied onto a registered request function to handle its inputs.
Raises:
  • exception – if an unknown exception was caught (or forced) during the decorated function’s execution.
  • Exception – original exception if it is known.