2015-03-14 09:06:31 -04:00
|
|
|
from __future__ import unicode_literals
|
|
|
|
from moto.core.exceptions import RESTError
|
|
|
|
|
|
|
|
|
|
|
|
class SNSNotFoundError(RESTError):
|
|
|
|
code = 404
|
|
|
|
|
2021-01-31 14:29:10 +02:00
|
|
|
def __init__(self, message, **kwargs):
|
|
|
|
super(SNSNotFoundError, self).__init__("NotFound", message, **kwargs)
|
2017-03-16 22:28:30 -04:00
|
|
|
|
|
|
|
|
2019-10-12 20:36:15 +02:00
|
|
|
class ResourceNotFoundError(RESTError):
|
|
|
|
code = 404
|
|
|
|
|
|
|
|
def __init__(self):
|
|
|
|
super(ResourceNotFoundError, self).__init__(
|
2019-10-31 08:44:26 -07:00
|
|
|
"ResourceNotFound", "Resource does not exist"
|
|
|
|
)
|
2019-10-12 20:36:15 +02:00
|
|
|
|
|
|
|
|
2017-03-16 22:28:30 -04:00
|
|
|
class DuplicateSnsEndpointError(RESTError):
|
|
|
|
code = 400
|
|
|
|
|
|
|
|
def __init__(self, message):
|
2019-10-31 08:44:26 -07:00
|
|
|
super(DuplicateSnsEndpointError, self).__init__("DuplicateEndpoint", message)
|
2017-03-16 22:28:30 -04:00
|
|
|
|
|
|
|
|
|
|
|
class SnsEndpointDisabled(RESTError):
|
|
|
|
code = 400
|
|
|
|
|
|
|
|
def __init__(self, message):
|
2019-10-31 08:44:26 -07:00
|
|
|
super(SnsEndpointDisabled, self).__init__("EndpointDisabled", message)
|
2017-09-08 03:19:34 +09:00
|
|
|
|
|
|
|
|
|
|
|
class SNSInvalidParameter(RESTError):
|
|
|
|
code = 400
|
|
|
|
|
|
|
|
def __init__(self, message):
|
2019-10-31 08:44:26 -07:00
|
|
|
super(SNSInvalidParameter, self).__init__("InvalidParameter", message)
|
2017-11-13 18:27:11 +00:00
|
|
|
|
|
|
|
|
|
|
|
class InvalidParameterValue(RESTError):
|
|
|
|
code = 400
|
|
|
|
|
|
|
|
def __init__(self, message):
|
2019-10-31 08:44:26 -07:00
|
|
|
super(InvalidParameterValue, self).__init__("InvalidParameterValue", message)
|
2019-08-25 16:48:14 +02:00
|
|
|
|
|
|
|
|
2019-10-12 20:36:15 +02:00
|
|
|
class TagLimitExceededError(RESTError):
|
|
|
|
code = 400
|
|
|
|
|
|
|
|
def __init__(self):
|
|
|
|
super(TagLimitExceededError, self).__init__(
|
2019-10-31 08:44:26 -07:00
|
|
|
"TagLimitExceeded",
|
|
|
|
"Could not complete request: tag quota of per resource exceeded",
|
|
|
|
)
|
2019-10-12 20:36:15 +02:00
|
|
|
|
|
|
|
|
2019-08-25 16:48:14 +02:00
|
|
|
class InternalError(RESTError):
|
|
|
|
code = 500
|
|
|
|
|
|
|
|
def __init__(self, message):
|
2019-10-31 08:44:26 -07:00
|
|
|
super(InternalError, self).__init__("InternalFailure", message)
|