1
0
forked from ScoDoc/ScoDoc

Améliore message erreur import étudiants via excel

This commit is contained in:
Emmanuel Viennet 2022-01-15 14:59:59 +01:00
parent 69d494c02c
commit da5445baa8

View File

@ -550,9 +550,9 @@ def _import_one_student(
formsemestre_id = values["codesemestre"]
try:
formsemestre_id = int(formsemestre_id)
except ValueError as exc:
except (ValueError, TypeError) as exc:
raise ScoValueError(
f"valeur invalide dans la colonne codesemestre, ligne {linenum+1}"
f"valeur invalide ou manquante dans la colonne codesemestre, ligne {linenum+1}"
) from exc
# recupere liste des groupes:
if formsemestre_id not in GroupIdInferers: