<s> """<STR_LIT>""" <EOL> __author__ = '<STR_LIT>' <EOL> from viewfinder . backend . resources . message . error_messages import ErrorDef <EOL> class ViewfinderError ( Exception ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self , error_def , ** error_args ) : <EOL> if isinstance ( error_def , ErrorDef ) : <EOL> self . id = error_def . id <EOL> message = error_def . format % error_args <EOL> else : <EOL> assert isinstance ( error_def , basestring ) <EOL> assert not error_args <EOL> self . id = None <EOL> message = error_def <EOL> super ( ViewfinderError , self ) . __init__ ( message ) <EOL> class AdminAPIError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class IdentityUnreachableError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class EmailError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class SMSError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class MigrationError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class HttpForbiddenError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> class PermissionError ( HttpForbiddenError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class TooManyGuessesError ( HttpForbiddenError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class ExpiredError ( HttpForbiddenError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class TooManyRetriesError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class CannotReadEncryptedSecretError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class TooManyOutstandingOpsError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class DBProvisioningExceededError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class DBLimitExceededError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class DBConditionalCheckFailedError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class InvalidRequestError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class NotFoundError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class CannotWaitError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class LockFailedError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class FailpointError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self , filename , lineno ) : <EOL> super ( FailpointError , self ) . __init__ ( '<STR_LIT>' ) <EOL> self . filename = filename <EOL> self . lineno = lineno <EOL> class ViewfinderConfigurationError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class LimitExceededError ( HttpForbiddenError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class ServiceUnavailableError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> pass <EOL> class StopOperationError ( ViewfinderError ) : <EOL> """<STR_LIT>""" <EOL> def __init__ ( self ) : <EOL> super ( StopOperationError , self ) . __init__ ( '<STR_LIT>' ) </s>
