From 4e2fab29d5faf9bee558030dc411c7b9371aa734 Mon Sep 17 00:00:00 2001 From: Emmanuel Viennet Date: Sun, 5 Sep 2021 18:14:16 +0200 Subject: [PATCH] fix typo role RespPe --- tools/import_scodoc7_user_db.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/import_scodoc7_user_db.py b/tools/import_scodoc7_user_db.py index 1cd7774f8..199f23e2c 100644 --- a/tools/import_scodoc7_user_db.py +++ b/tools/import_scodoc7_user_db.py @@ -59,7 +59,7 @@ def import_scodoc7_user_db(scodoc7_db="dbname=SCOUSERS"): roles7 = [] for role_dept in roles7: # Migre les rôles RespPeX, EnsX, AdminX, SecrX et ignore les autres - m = re.match(r"^(-?Ens|-?Secr|-?ResPe|-?Admin)(.*)$", role_dept) + m = re.match(r"^(-?Ens|-?Secr|-?RespPe|-?Admin)(.*)$", role_dept) if not m: msg = f"User {user_name}: role inconnu '{role_dept}' (ignoré)" current_app.logger.warning(msg) @@ -75,7 +75,7 @@ def import_scodoc7_user_db(scodoc7_db="dbname=SCOUSERS"): dept = m.group(2) role = Role.query.filter_by(name=role_name).first() if not role: - msg = f"User {user_name}: ignoring role '{role_dept}'" + msg = f"Role '{role_name}' introuvable. User {user_name}: ignoring role '{role_dept}'" current_app.logger.warning(msg) messages.append(msg) else: