Module aws_lambda_powertools.utilities.idempotency.exceptions
Idempotency errors
Classes
- class BaseError (*args: str | Exception | None)
- 
Expand source codeclass BaseError(Exception): """ Base error class that overwrites the way exception and extra information is printed. See https://github.com/aws-powertools/powertools-lambda-python/issues/1772 """ def __init__(self, *args: str | Exception | None): self.message = str(args[0]) if args else "" self.details = "".join(str(arg) for arg in args[1:]) if args[1:] else None def __str__(self): """ Return all arguments formatted or original message """ if self.message and self.details: return f"{self.message} - ({self.details})" return self.messageBase error class that overwrites the way exception and extra information is printed. See https://github.com/aws-powertools/powertools-lambda-python/issues/1772 Ancestors- builtins.Exception
- builtins.BaseException
 Subclasses- IdempotencyAlreadyInProgressError
- IdempotencyInconsistentStateError
- IdempotencyInvalidStatusError
- IdempotencyItemAlreadyExistsError
- IdempotencyItemNotFoundError
- IdempotencyKeyError
- IdempotencyModelTypeError
- IdempotencyNoSerializationModelError
- IdempotencyPersistenceConfigError
- IdempotencyPersistenceConnectionError
- IdempotencyPersistenceConsistencyError
- IdempotencyPersistenceLayerError
- IdempotencyValidationError
 
- class IdempotencyAlreadyInProgressError (*args: str | Exception | None)
- 
Expand source codeclass IdempotencyAlreadyInProgressError(BaseError): """ Execution with idempotency key is already in progress """Execution with idempotency key is already in progress Ancestors- BaseError
- builtins.Exception
- builtins.BaseException
 
- class IdempotencyInconsistentStateError (*args: str | Exception | None)
- 
Expand source codeclass IdempotencyInconsistentStateError(BaseError): """ State is inconsistent across multiple requests to persistence store """State is inconsistent across multiple requests to persistence store Ancestors- BaseError
- builtins.Exception
- builtins.BaseException
 
- class IdempotencyInvalidStatusError (*args: str | Exception | None)
- 
Expand source codeclass IdempotencyInvalidStatusError(BaseError): """ An invalid status was provided """An invalid status was provided Ancestors- BaseError
- builtins.Exception
- builtins.BaseException
 
- class IdempotencyItemAlreadyExistsError (*args: str | Exception | None, old_data_record: DataRecord | None = None)
- 
Expand source codeclass IdempotencyItemAlreadyExistsError(BaseError): """ Item attempting to be inserted into persistence store already exists and is not expired """ def __init__(self, *args: str | Exception | None, old_data_record: DataRecord | None = None): self.old_data_record = old_data_record super().__init__(*args) def __str__(self): """ Return all arguments formatted or original message """ old_data_record = f" from [{(str(self.old_data_record))}]" if self.old_data_record else "" message = super().__str__() return f"{message}{old_data_record}"Item attempting to be inserted into persistence store already exists and is not expired Ancestors- BaseError
- builtins.Exception
- builtins.BaseException
 
- class IdempotencyItemNotFoundError (*args: str | Exception | None)
- 
Expand source codeclass IdempotencyItemNotFoundError(BaseError): """ Item does not exist in persistence store """Item does not exist in persistence store Ancestors- BaseError
- builtins.Exception
- builtins.BaseException
 
- class IdempotencyKeyError (*args: str | Exception | None)
- 
Expand source codeclass IdempotencyKeyError(BaseError): """ Payload does not contain an idempotent key """Payload does not contain an idempotent key Ancestors- BaseError
- builtins.Exception
- builtins.BaseException
 
- class IdempotencyModelTypeError (*args: str | Exception | None)
- 
Expand source codeclass IdempotencyModelTypeError(BaseError): """ Model type does not match expected payload output """Model type does not match expected payload output Ancestors- BaseError
- builtins.Exception
- builtins.BaseException
 
- class IdempotencyNoSerializationModelError (*args: str | Exception | None)
- 
Expand source codeclass IdempotencyNoSerializationModelError(BaseError): """ No model was supplied to the serializer """No model was supplied to the serializer Ancestors- BaseError
- builtins.Exception
- builtins.BaseException
 
- class IdempotencyPersistenceConfigError (*args: str | Exception | None)
- 
Expand source codeclass IdempotencyPersistenceConfigError(BaseError): """ The idempotency persistency configuration was unsupported """The idempotency persistency configuration was unsupported Ancestors- BaseError
- builtins.Exception
- builtins.BaseException
 
- class IdempotencyPersistenceConnectionError (*args: str | Exception | None)
- 
Expand source codeclass IdempotencyPersistenceConnectionError(BaseError): """ Idempotency persistence connection error """Idempotency persistence connection error Ancestors- BaseError
- builtins.Exception
- builtins.BaseException
 
- class IdempotencyPersistenceConsistencyError (*args: str | Exception | None)
- 
Expand source codeclass IdempotencyPersistenceConsistencyError(BaseError): """ Idempotency persistency consistency error, needs to be removed """Idempotency persistency consistency error, needs to be removed Ancestors- BaseError
- builtins.Exception
- builtins.BaseException
 
- class IdempotencyPersistenceLayerError (*args: str | Exception | None)
- 
Expand source codeclass IdempotencyPersistenceLayerError(BaseError): """ Unrecoverable error from the data store """Unrecoverable error from the data store Ancestors- BaseError
- builtins.Exception
- builtins.BaseException
 
- class IdempotencyValidationError (*args: str | Exception | None)
- 
Expand source codeclass IdempotencyValidationError(BaseError): """ Payload does not match stored idempotency record """Payload does not match stored idempotency record Ancestors- BaseError
- builtins.Exception
- builtins.BaseException