From 0844a8e6de1dcd35eba23ef55e8aca6500dc73ff Mon Sep 17 00:00:00 2001 From: Johan Schreurs Date: Mon, 15 May 2023 10:05:54 +0200 Subject: [PATCH 1/2] Add proj:bbox to BatchJobsMetadata https://github.com/Open-EO/openeo-geotrellis-extensions/issues/72 --- openeo_driver/backend.py | 2 ++ openeo_driver/views.py | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/openeo_driver/backend.py b/openeo_driver/backend.py index 8b0b9044..abdf7e7c 100644 --- a/openeo_driver/backend.py +++ b/openeo_driver/backend.py @@ -298,7 +298,9 @@ class BatchJobMetadata(NamedTuple): # TODO: #190 openEO API associates `links` with the job *result* metadata, not the job itself links: List[Dict] = None usage: Dict = None + # TODO #190 the STAC projection extension fields "proj:..." are not batch job metadata, but batch job *result* metadata: proj_shape: List[int] = None + proj_bbox: List[int] = None @property def duration(self) -> Union[timedelta, None]: diff --git a/openeo_driver/views.py b/openeo_driver/views.py index de99d277..24c87fe8 100644 --- a/openeo_driver/views.py +++ b/openeo_driver/views.py @@ -744,6 +744,9 @@ def _properties_from_job_info(job_info: BatchJobMetadata) -> dict: if job_info.epsg: properties["proj:epsg"] = job_info.epsg + if job_info.proj_bbox: + properties["proj:bbox"] = job_info.proj_bbox + if job_info.proj_shape: properties["proj:shape"] = job_info.proj_shape @@ -1178,6 +1181,8 @@ def _get_job_result_item(job_id, item_id, user_id): if job_info.proj_shape: properties["proj:shape"] = job_info.proj_shape + if job_info.proj_bbox: + properties["proj:bbox"] = job_info.proj_bbox stac_item = { "type": "Feature", From 5b37ccaea60ba6d6b07a88e3cdcb39af735646ca Mon Sep 17 00:00:00 2001 From: Johan Schreurs Date: Tue, 16 May 2023 09:58:00 +0200 Subject: [PATCH 2/2] Bump minor version https://github.com/Open-EO/openeo-geotrellis-extensions/issues/72 --- openeo_driver/_version.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openeo_driver/_version.py b/openeo_driver/_version.py index ebd19e63..bfbbc8da 100644 --- a/openeo_driver/_version.py +++ b/openeo_driver/_version.py @@ -1 +1 @@ -__version__ = "0.48.1a1" +__version__ = "0.49.0a1"