From fa3d784fa4a07b71fa65b458d94bb10d07b05ef4 Mon Sep 17 00:00:00 2001 From: Marco Cucchi Date: Thu, 1 Aug 2024 17:32:58 +0200 Subject: [PATCH] update --- cads_processing_api_service/utils.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cads_processing_api_service/utils.py b/cads_processing_api_service/utils.py index 63a3999..c4a0f3c 100644 --- a/cads_processing_api_service/utils.py +++ b/cads_processing_api_service/utils.py @@ -506,13 +506,13 @@ def get_results_from_job( if job_status == "successful": try: asset_value = job.cache_entry.result["args"][0] # type: ignore - if "href" in asset_value: - asset_value["href"] = update_results_href(asset_value["href"]) - results = {"asset": {"value": asset_value}} except Exception: raise exceptions.JobResultsExpired( detail=f"results of job {job_id} expired" ) + if "href" in asset_value: + asset_value["href"] = update_results_href(asset_value["href"]) + results = {"asset": {"value": asset_value}} elif job_status == "failed": error_messages = get_job_events( job=job, session=session, event_type="user_visible_error"