From 5a8add1aacb58954682b354301c3b2b5cc019206 Mon Sep 17 00:00:00 2001 From: Emmanuel Viennet Date: Fri, 1 Jul 2022 09:48:08 +0200 Subject: [PATCH] =?UTF-8?q?Fix:=20calcul=20malus=20sur=20donn=C3=A9es=20vi?= =?UTF-8?q?des?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/comp/moy_ue.py | 3 ++- sco_version.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app/comp/moy_ue.py b/app/comp/moy_ue.py index f1dba24d8..5f432387c 100644 --- a/app/comp/moy_ue.py +++ b/app/comp/moy_ue.py @@ -496,7 +496,8 @@ def compute_malus( """ ues_idx = [ue.id for ue in ues] malus = pd.DataFrame(index=modimpl_inscr_df.index, columns=ues_idx, dtype=float) - + if len(sem_modimpl_moys.flat) == 0: # vide + return malus if len(sem_modimpl_moys.shape) > 2: # BUT: ne retient que la 1er composante du malus qui est scalaire # au sens ou chaque note de malus n'affecte que la moyenne de l'UE diff --git a/sco_version.py b/sco_version.py index 6cb2218c2..b58e1e77d 100644 --- a/sco_version.py +++ b/sco_version.py @@ -1,7 +1,7 @@ # -*- mode: python -*- # -*- coding: utf-8 -*- -SCOVERSION = "9.3.11" +SCOVERSION = "9.3.12" SCONAME = "ScoDoc"