pulp.exceptions¶
All exceptions documented here should be imported directly from the pulp.exceptions
namespace.
pulp.exceptions.base¶
-
exception
pulpcore.exceptions.base.
PulpException
(error_code)¶ Base exception class for Pulp.
- Parameters
error_code (str) – unique error code
-
http_status_code
= 500¶
-
exception
pulpcore.exceptions.base.
ResourceImmutableError
(model)¶ Exceptions that are raised due to trying to update an immutable resource
- Parameters
model (pulpcore.app.models.Model) – that the user is trying to update
-
pulpcore.exceptions.base.
exception_to_dict
(exc, traceback=None)¶ Return a dictionary representation of an Exception.
- Parameters
exc (Exception) – Exception that is being serialized
traceback (str) – String representation of a traceback generated when the exception occurred.
- Returns
dictionary representing the Exception
- Return type
dict
pulp.exceptions.http¶
-
exception
pulpcore.exceptions.http.
MissingResource
(**resources)¶ ” Base class for missing resource exceptions.
Exceptions that are raised due to requests for resources that do not exist should inherit from this base class.
- Parameters
resources (dict) – keyword arguments of resource_type=resource_id
-
http_status_code
= 404¶