summaryrefslogtreecommitdiff
path: root/poezio/core/structs.py
diff options
context:
space:
mode:
authormathieui <mathieui@mathieui.net>2020-12-12 22:51:34 +0100
committermathieui <mathieui@mathieui.net>2021-01-28 19:03:54 +0100
commit08f48b0c8be7535754ba9494d13276f69485bd44 (patch)
treefae56a438190475259347cd1f30e1dc42808b972 /poezio/core/structs.py
parente1720c8e2378dfae3a165cf250036e3443dd7174 (diff)
downloadpoezio-08f48b0c8be7535754ba9494d13276f69485bd44.tar.gz
poezio-08f48b0c8be7535754ba9494d13276f69485bd44.tar.bz2
poezio-08f48b0c8be7535754ba9494d13276f69485bd44.tar.xz
poezio-08f48b0c8be7535754ba9494d13276f69485bd44.zip
Move get_error_message to common
Diffstat (limited to 'poezio/core/structs.py')
-rw-r--r--poezio/core/structs.py35
1 files changed, 1 insertions, 34 deletions
diff --git a/poezio/core/structs.py b/poezio/core/structs.py
index a75f1e94..ae4ebe7d 100644
--- a/poezio/core/structs.py
+++ b/poezio/core/structs.py
@@ -5,43 +5,10 @@ from dataclasses import dataclass
from typing import Any, Callable, List, Dict
__all__ = [
- 'ERROR_AND_STATUS_CODES', 'DEPRECATED_ERRORS', 'POSSIBLE_SHOW', 'Status',
+ 'POSSIBLE_SHOW', 'Status',
'Command', 'Completion'
]
-# http://xmpp.org/extensions/xep-0045.html#errorstatus
-ERROR_AND_STATUS_CODES = {
- '401': 'A password is required',
- '403': 'Permission denied',
- '404': 'The room doesn’t exist',
- '405': 'Your are not allowed to create a new room',
- '406': 'A reserved nick must be used',
- '407': 'You are not in the member list',
- '409': 'This nickname is already in use or has been reserved',
- '503': 'The maximum number of users has been reached',
-}
-
-# http://xmpp.org/extensions/xep-0086.html
-DEPRECATED_ERRORS = {
- '302': 'Redirect',
- '400': 'Bad request',
- '401': 'Not authorized',
- '402': 'Payment required',
- '403': 'Forbidden',
- '404': 'Not found',
- '405': 'Not allowed',
- '406': 'Not acceptable',
- '407': 'Registration required',
- '408': 'Request timeout',
- '409': 'Conflict',
- '500': 'Internal server error',
- '501': 'Feature not implemented',
- '502': 'Remote server error',
- '503': 'Service unavailable',
- '504': 'Remote server timeout',
- '510': 'Disconnected',
-}
-
POSSIBLE_SHOW = {
'available': None,
'chat': 'chat',