diff options
author | Evgeny Zinoviev <me@ch1p.io> | 2021-03-23 01:59:15 +0300 |
---|---|---|
committer | Evgeny Zinoviev <me@ch1p.io> | 2021-03-23 01:59:15 +0300 |
commit | 8c9d10fba12fad2fa39390df42cbc33f7b89e89e (patch) | |
tree | 606dddeaa2c60e8c65aed6baccc2c3abc4ce7678 | |
parent | 876c206153e5d71004a83d203aa8def2f5cd5cf8 (diff) |
rename error class
-rw-r--r-- | e3372.py | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -83,7 +83,7 @@ class E3372: if message_node: message = message_node.get_text() - raise E3372Error(code, message=message) + raise APIError(code, message=message) return soup.find('response') @@ -101,7 +101,7 @@ class SMS: return int(datetime.strptime(self.date, '%Y-%m-%d %H-%M-%S').strftime("%s")) -class E3372Error(Exception): +class APIError(Exception): def __init__(self, error_code, message='', *args, **kwargs): self.error_code = error_code self.traceback = sys.exc_info() |