From d5563170efeb2a4bef7ba8019af638c6cf1c1beb Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Sat, 28 Nov 2020 19:39:18 +0100 Subject: [PATCH] Fix syntax issue found by linter --- src/yunohost/tools.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/yunohost/tools.py b/src/yunohost/tools.py index 8dab6bcff..96bd01ed6 100644 --- a/src/yunohost/tools.py +++ b/src/yunohost/tools.py @@ -166,7 +166,7 @@ def tools_adminpw(new_password, check_strength=True): # An IOError may be thrown if for some reason we can't read/write /etc/passwd # A KeyError could also be thrown if 'root' is not in /etc/passwd in the first place (for example because no password defined ?) # (c.f. the line about getspnam) - except IOError, KeyError: + except (IOError, KeyError): logger.warning(m18n.n('root_password_desynchronized')) return