ironic_inspector.common.exception module¶
Ironic base exception handling.
Includes decorator for re-raising Ironic-type exceptions.
SHOULD include dedicated exception logging.
- exception ironic_inspector.common.exception.BadRequest(message=None, **kwargs)[source]¶
Bases:
IronicException
- code = 400¶
- exception ironic_inspector.common.exception.ConfigInvalid(message=None, **kwargs)[source]¶
Bases:
IronicException
- exception ironic_inspector.common.exception.IronicException(message=None, **kwargs)[source]¶
Bases:
Exception
Base Ironic Exception
To correctly use this class, inherit from it and define a ‘_msg_fmt’ property. That _msg_fmt will get printf’d with the keyword arguments provided to the constructor.
If you need to access the message from an exception you should use str(exc)
- code = 500¶
- headers = {}¶
- safe = False¶
- exception ironic_inspector.common.exception.ServiceLookupFailure(message=None, **kwargs)[source]¶
Bases:
IronicException
- exception ironic_inspector.common.exception.ServiceRegistrationFailure(message=None, **kwargs)[source]¶
Bases:
IronicException
- exception ironic_inspector.common.exception.Unauthorized(message=None, **kwargs)[source]¶
Bases:
IronicException
- code = 401¶
- headers = {'WWW-Authenticate': 'Basic realm="Baremetal API"'}¶