-
Notifications
You must be signed in to change notification settings - Fork 0
/
errors.py
95 lines (68 loc) · 1.52 KB
/
errors.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
"""Exceptions and error-handling methods."""
ERROR_CODES = ['100002', '100003', '100004', '108001', '108002', '108003',
'108006', '108007', '120001', '125001', '125002', '125003']
class ErrorSystemNotSupport(Exception):
"""
System not supported error -- 100002
"""
pass
class ErrorSystemNoRights(Exception):
"""
System has no rights error -- 100003
"""
pass
class ErrorSystemBusy(Exception):
"""
System is busy error -- 100004
"""
pass
class ErrorLoginUsernameWrong(Exception):
"""
Wrong username error -- 108001
"""
pass
class ErrorLoginPasswordWrong(Exception):
"""
Wrong password error -- 108002
"""
pass
class ErrorUserAlreadyLogin(Exception):
"""
User is logged in error -- 108003
"""
pass
class ErrorLoginUsernamePwdWrong(Exception):
"""
Wrong username and password --- 108006
"""
pass
class ErrorLoginUsernamePwdOverrun(Exception):
"""
Wrong username and password --- 108007
"""
pass
class ErrorVoiceBusy(Exception):
"""
Voice busy error -- 120001
"""
pass
class ErrorWrongToken(Exception):
"""
Wrong token error -- 125001
"""
pass
class ErrorWrongSession(Exception):
"""
Wrong session error -- 125002
"""
pass
class ErrorWrongSessionToken(Exception):
"""
Wrong session token error -- 125003
"""
pass
class ErrorUnknownError(Exception):
"""
Any other unknown error
"""
pass