runway.cfngin.exceptions module
CFNgin exceptions.
- exception runway.cfngin.exceptions.CfnginError[source]
Bases:
runway.exceptions.RunwayError
Base class for custom exceptions raised by Runway.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.CancelExecution[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when we want to cancel executing the plan.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.CfnginBucketAccessDenied[source]
Bases:
runway.cfngin.exceptions.CfnginError
Access denied to CFNgin bucket.
This can occur when the bucket exists in another AWS account and/or the credentials being used do not have adequate permissions to access the bucket.
- __init__(*, bucket_name: str) None [source]
Instantiate class.
- Parameters
bucket_name – Name of the CFNgin bucket.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.CfnginBucketNotFound[source]
Bases:
runway.cfngin.exceptions.CfnginError
CFNgin bucket specified or default bucket being used but it does not exist.
This can occur when using a custom stack to deploy the CFNgin bucket but the custom stack does not create bucket that is expected.
- __init__(*, bucket_name: str) None [source]
Instantiate class.
- Parameters
bucket_name – Name of the CFNgin bucket.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.CfnginBucketRequired[source]
Bases:
runway.cfngin.exceptions.CfnginError
CFNgin bucket is required to use a feature but it not provided/disabled.
- __init__(*, config_path: Optional[AnyPath] = None, reason: Optional[str] = None) None [source]
Instantiate class.
- Parameters
config_path – Path to the CFNgin config file.
reason – Reason why CFNgin bucket is needed.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.CfnginOnlyLookupError[source]
Bases:
runway.cfngin.exceptions.CfnginError
Attempted to use a CFNgin lookup outside of CFNgin.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.ChangesetDidNotStabilize[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when the applying a changeset fails.
- __init__(change_set_id: str) None [source]
Instantiate class.
- Parameters
change_set_id – The changeset that failed.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.GraphError[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when the graph is invalid (e.g. acyclic dependencies).
- __init__(exception: Exception, stack: str, dependency: str) None [source]
Instantiate class.
- Parameters
exception – The exception that was raised by the invalid graph.
stack – Name of the stack causing the error.
dependency – Name of the dependency causing the error.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.ImproperlyConfigured[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when a component is improperly configured.
- __init__(kls: Any, error: Exception, *args: Any, **kwargs: Any) None [source]
Instantiate class.
- Parameters
kls – The class that was improperly configured.
error – The exception that was raised when trying to use cls.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.InvalidConfig[source]
Bases:
runway.cfngin.exceptions.CfnginError
Provided config file is invalid.
- __init__(errors: Union[str, List[Union[Exception, str]]]) None [source]
Instantiate class.
- Parameters
errors – Errors or error messages that are raised to identify that a config is invalid.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.InvalidDockerizePipConfiguration[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when the provided configuration for dockerized pip is invalid.
- __init__(msg: str) None [source]
Instantiate class.
- Parameters
msg – The reason for the error being raised.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.InvalidUserdataPlaceholder[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when a placeholder name in raw_user_data is not valid.
E.g
${100}
would raise this.- __init__(blueprint_name: str, exception_message: str, *args: Any, **kwargs: Any) None [source]
Instantiate class.
- Parameters
blueprint_name – Name of the blueprint with invalid userdata placeholder.
exception_message – Message from the exception that was raised while parsing the userdata.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.MissingEnvironment[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when an environment lookup is used but the key doesn’t exist.
- __init__(key: str, *args: Any, **kwargs: Any) None [source]
Instantiate class.
- Parameters
key – The key that was used but doesn’t exist in the environment.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.MissingParameterException[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised if a required parameter with no default is missing.
- __init__(parameters: List[str], *args: Any, **kwargs: Any) None [source]
Instantiate class.
- Parameters
parameters – A list of the parameters that are missing.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.MissingVariable[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when a variable with no default is not provided a value.
- __init__(blueprint_name: str, variable_name: str, *args: Any, **kwargs: Any) None [source]
Instantiate class.
- Parameters
blueprint_name – Name of the blueprint.
variable_name – Name of the variable missing a value.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.PipError[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when pip returns a non-zero exit code.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.PipenvError[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when pipenv returns a non-zero exit code.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.PersistentGraphCannotLock[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when the persistent graph in S3 cannot be locked.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.PersistentGraphCannotUnlock[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when the persistent graph in S3 cannot be unlocked.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.PersistentGraphLocked[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when the persistent graph in S3 is lock.
The action being executed requires it to be unlocked before attempted.
- __init__(*, message: Optional[str] = None, reason: Optional[str] = None) None [source]
Instantiate class.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.PersistentGraphLockCodeMismatch[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when the provided persistent graph lock code does not match.
The code used to unlock the persistent graph must match the s3 object lock code.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.PersistentGraphUnlocked[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when the persistent graph in S3 is unlock.
The action being executed requires it to be locked before attempted.
- __init__(message: Optional[str] = None, reason: Optional[str] = None) None [source]
Instantiate class.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.PlanFailed[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised if any step of a plan fails.
- __init__(failed_steps: List[Step], *args: Any, **kwargs: Any) None [source]
Instantiate class.
- Parameters
failed_steps – The steps that failed.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.StackDidNotChange[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when there are no changes to be made by the provider.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.StackDoesNotExist[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when a stack does not exist in AWS.
- __init__(stack_name: str, *args: Any, **kwargs: Any) None [source]
Instantiate class.
- Parameters
stack_name – Name of the stack that does not exist.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.StackUpdateBadStatus[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised if the state of a stack can’t be handled.
- __init__(stack_name: str, stack_status: str, reason: str, *args: Any, **kwargs: Any) None [source]
Instantiate class.
- Parameters
stack_name – Name of the stack.
stack_status – The stack’s status.
reason – The reason for the current status.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.StackFailed[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when a stack action fails.
Primarily used with hooks that act on stacks.
- __init__(stack_name: str, status_reason: Optional[str] = None) None [source]
Instantiate class.
- Parameters
stack_name – Name of the stack.
status_reason – The reason for the current status.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.UnableToExecuteChangeSet[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised if changeset execution status is not
AVAILABLE
.- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.UnhandledChangeSetStatus[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when creating a changeset failed for an unhandled reason.
Handled failure reasons include: no changes
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.UnresolvedBlueprintVariable[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when trying to use a variable before it has been resolved.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.UnresolvedBlueprintVariables[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when trying to use variables before they has been resolved.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception runway.cfngin.exceptions.ValidatorError[source]
Bases:
runway.cfngin.exceptions.CfnginError
Used for errors raised by custom validators of blueprint variables.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- __init__(variable: str, validator: str, value: str, exception: Optional[Exception] = None) None [source]
Instantiate class.
- Parameters
variable – The variable that failed validation.
validator – The validator that was not passed.
value – The value of the variable that did not pass the validator.
exception – The exception raised by the validator.
- exception runway.cfngin.exceptions.VariableTypeRequired[source]
Bases:
runway.cfngin.exceptions.CfnginError
Raised when a variable defined in a blueprint is missing a type.
- __new__(**kwargs)
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.