diff --git a/app/comp/res_common.py b/app/comp/res_common.py index 9ba073a4f..706e37f9d 100644 --- a/app/comp/res_common.py +++ b/app/comp/res_common.py @@ -432,7 +432,7 @@ class ResultatsSemestre(ResultatsCache): ue_cap_dict["compense_formsemestre_id"] = None return ue_cap_dict - def get_etud_ue_status(self, etudid: int, ue_id: int) -> dict: + def get_etud_ue_status(self, etudid: int, ue_id: int) -> dict | None: """L'état de l'UE pour cet étudiant. Result: dict, ou None si l'UE n'est pas dans ce semestre. { @@ -470,7 +470,7 @@ class ResultatsSemestre(ResultatsCache): "ects": 0.0, "ects_ue": ue.ects, } - if not ue_id in self.etud_moy_ue: + if not ue_id in self.etud_moy_ue or not etudid in self.etud_moy_ue[ue_id]: return None if not self.validations: self.validations = res_sem.load_formsemestre_validations(self.formsemestre) diff --git a/app/scodoc/sco_poursuite_dut.py b/app/scodoc/sco_poursuite_dut.py index 2ada0c6b2..c271628a2 100644 --- a/app/scodoc/sco_poursuite_dut.py +++ b/app/scodoc/sco_poursuite_dut.py @@ -72,9 +72,7 @@ def etud_get_poursuite_info(sem: dict, etud: dict) -> dict: moy_ues.append( ( ue["acronyme"], - scu.fmt_note( - nt.get_etud_ue_status(etudid, ue["ue_id"])["moy"] - ), + scu.fmt_note(ue_status["moy"]), ) ) else: diff --git a/sco_version.py b/sco_version.py index ff1b244fb..8c642266c 100644 --- a/sco_version.py +++ b/sco_version.py @@ -1,7 +1,7 @@ # -*- mode: python -*- # -*- coding: utf-8 -*- -SCOVERSION = "9.6.945" +SCOVERSION = "9.6.946" SCONAME = "ScoDoc"