From ad3a9322cacc129265caa3563de7cb30bb808e69 Mon Sep 17 00:00:00 2001 From: Andria Capai Date: Fri, 8 Mar 2024 19:33:04 +0100 Subject: [PATCH] fix(test): WIP - error based on id_nomenclature Error message : raise sa_exc.InvalidRequestError( sqlalchemy.exc.InvalidRequestError: 'TDatasets.nomenclature_data_origin' is not available due to lazy='raise' See: FIXME of this commit Reviewed-by: andriacap --- backend/geonature/core/gn_synthese/imports/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/backend/geonature/core/gn_synthese/imports/__init__.py b/backend/geonature/core/gn_synthese/imports/__init__.py index eccdcb1353..d9ced0b32b 100644 --- a/backend/geonature/core/gn_synthese/imports/__init__.py +++ b/backend/geonature/core/gn_synthese/imports/__init__.py @@ -205,6 +205,8 @@ def update_batch_progress(batch, step): if ( current_app.config["IMPORT"]["CHECK_PRIVATE_JDD_BLURING"] # and not current_app.config["IMPORT"]["FILL_MISSING_NOMENCLATURE_WITH_DEFAULT_VALUE"] # XXX + # FIXME: raise sa_exc.InvalidRequestError( + # sqlalchemy.exc.InvalidRequestError: 'TDatasets.nomenclature_data_origin' is not available due to lazy='raise' and imprt.dataset.nomenclature_data_origin.mnemonique == "Privée" ): check_nomenclature_blurring(imprt, entity, fields["id_nomenclature_blurring"])