changeset feb8125c72d2 in tryton:default
details: https://hg.tryton.org/tryton?cmd=changeset;node=feb8125c72d2
description:
Catch any exception for server version RPC
It is the first method called with the input of the user.
The login window does not support that it raises an exception and as a
lot of
different exceptions can be raised (and may change depending of Python
version), we must catch all of them. It does not hide any programming
error as
they are logged.
issue9408
review292561004
diffstat:
tryton/rpc.py | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
diffs (20 lines):
diff -r 90071de08bc7 -r feb8125c72d2 tryton/rpc.py
--- a/tryton/rpc.py Mon Oct 26 21:25:47 2020 +0100
+++ b/tryton/rpc.py Mon Oct 26 21:28:47 2020 +0100
@@ -3,7 +3,6 @@
import http.client
import logging
import socket
-import ssl
import os
try:
from http import HTTPStatus
@@ -67,7 +66,7 @@
result = connection.common.server.version()
logging.getLogger(__name__).debug(repr(result))
return result
- except (Fault, socket.error, ssl.SSLError, ssl.CertificateError) as e:
+ except Exception as e:
logging.getLogger(__name__).error(e)
return None