Skip to content

Commit

Permalink
#156: catch InvalidProductError when we try to get cloud_coverage pro…
Browse files Browse the repository at this point in the history
…perty
  • Loading branch information
jteulade committed Jun 10, 2024
1 parent 8e001d0 commit 1106de5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion eoreader/stac/stac_extensions.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
get_media_type,
repr_multiline_str,
)
from eoreader.exceptions import InvalidProductError


class EoExt:
Expand All @@ -77,7 +78,7 @@ def __init__(self, prod, **kwargs):
try:
if prod._has_cloud_cover:
self.cloud_cover = prod.get_cloud_cover()
except AttributeError:
except (AttributeError, InvalidProductError):
pass

self.bands = prod.bands
Expand Down

0 comments on commit 1106de5

Please sign in to comment.