mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-06-03 02:57:25 +02:00
handling 99 error message
This commit is contained in:
parent
51375059c1
commit
74c7e6528f
2 changed files with 10 additions and 0 deletions
|
@ -67,6 +67,10 @@ class RegistryError(Exception):
|
|||
def should_retry(self):
|
||||
return self.code == ErrorCode.COMMAND_FAILED
|
||||
|
||||
# connection errors have error code of None and [Errno 99] in the err message
|
||||
def is_connection_error(self):
|
||||
return self.code is None
|
||||
|
||||
def is_session_error(self):
|
||||
return self.code is not None and (self.code >= 2501 and self.code <= 2502)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue