From e063610721279c16be936862c10547215f3b11d3 Mon Sep 17 00:00:00 2001 From: Tisham Dhar Date: Wed, 3 Jun 2020 03:39:51 +0000 Subject: [PATCH] #132 Account for new geom in odc-1.8.0 --- cubedash/summary/_extents.py | 5 ++++- requirements-docker.txt | 4 ++-- setup.py | 2 +- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/cubedash/summary/_extents.py b/cubedash/summary/_extents.py index 0d6c32883..cdcbadeb9 100644 --- a/cubedash/summary/_extents.py +++ b/cubedash/summary/_extents.py @@ -507,7 +507,10 @@ def geographic_extent(self, region_code: str) -> GeometryCollection: # So we're now converting to shapely to do it. # TODO: Is there a nicer way to do this? # pylint: disable=protected-access - return shapely.wkb.loads(extent._geom.ExportToWkb()) + try: + return shapely.wkb.loads(extent._geom.ExportToWkb()) + except AttributeError: + return extent.geom def region_label(self, region_code: str) -> str: return "Tile {:+d}, {:+d}".format(*_from_xy_region_code(region_code)) diff --git a/requirements-docker.txt b/requirements-docker.txt index 98a70cb6f..6e7b57297 100644 --- a/requirements-docker.txt +++ b/requirements-docker.txt @@ -1,3 +1,3 @@ ---extra-index-url https://packages.dea.ga.gov.au/ +--extra-index-url https://packages.dea.ga.gov.au/ --pre digitalearthau -datacube +datacube>=1.8.0 diff --git a/setup.py b/setup.py index 8657b126c..8bcd95ef6 100755 --- a/setup.py +++ b/setup.py @@ -48,7 +48,7 @@ "cachetools", "click", "dataclasses>=0.6;python_version<'3.7'", - "datacube>=1.7", + "datacube>=1.8", "fiona", "flask", "Flask-Caching",