Skip to content

Commit 876aa38

Browse files
committed
fix: error catching for when openeo job was deleted
1 parent c3efca2 commit 876aa38

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

app/platforms/implementations/openeo.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -238,8 +238,12 @@ async def get_job_status(
238238
) -> ProcessingStatusEnum:
239239
logger.debug(f"Fetching job status for openEO job with ID {job_id}")
240240
connection = await self._setup_connection(user_token, details.endpoint)
241-
job = connection.job(job_id)
242-
return self._map_openeo_status(job.status())
241+
try:
242+
job = connection.job(job_id)
243+
return self._map_openeo_status(job.status())
244+
except Exception as e:
245+
logger.error(f"Error occurred while fetching job status for job {job_id}: {e}")
246+
return ProcessingStatusEnum.UNKNOWN
243247

244248
async def get_job_results(
245249
self, user_token: str, job_id: str, details: ServiceDetails

0 commit comments

Comments
 (0)