From 11c648ac366c79922603fe027ae7b4de15b9d171 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roberto=20Trevi=C3=B1o?= Date: Sun, 29 Nov 2026 01:40:55 -0600 Subject: [PATCH] Promotion docs name the configured reports --- webapi/models.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/webapi/models.py b/webapi/models.py index 1fab3cd..cce5fda 100644 --- a/webapi/models.py +++ b/webapi/models.py @@ -56,7 +56,8 @@ def read_report(domain: Domain, name: str, version: int, report: str) -> Respons @router.post("/{domain}/{name}/versions/{version}/reports/clinical_validation") def add_clinical_validation(domain: Domain, name: str, version: int, file: UploadFile) -> dict: - """The clinical team's validation of a version: the third report promotion needs.""" + """The clinical team's validation of a version: the third report, which promotion needs + unless the site left it out of PROMOTION_REPORTS.""" registry.add_report(f"{domain.value}.{name}", version, "clinical_validation", file.filename or "report", file.file.read()) # fmt: skip return {"reports": sorted(registry.reports(f"{domain.value}.{name}", version))} @@ -64,8 +65,9 @@ def add_clinical_validation(domain: Domain, name: str, version: int, file: Uploa @router.post("/{domain}/{name}/versions/{version}/promote") def promote(domain: Domain, name: str, version: int) -> dict: - """The version risk batches come from from now on; refused (409) without its three - reports: technical validation, interpretability and clinical validation.""" + """The version risk batches come from from now on; refused (409) without the reports + the site requires (PROMOTION_REPORTS; default: technical validation, interpretability + and clinical validation).""" try: registry.promote(f"{domain.value}.{name}", version) except registry.MissingReports as e: