Skip to content

Commit

Permalink
catch validity error for extra matches, closes scottstanie#29
Browse files Browse the repository at this point in the history
  • Loading branch information
scottstanie committed Jan 7, 2022
1 parent c6f75b6 commit 40b431e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
9 changes: 4 additions & 5 deletions eof/scihubclient.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,11 +128,10 @@ def query_orbit_by_dt(
mission,
product_type="AUX_POEORB",
)
result = (
self._select_orbit(products, dt, dt + datetime.timedelta(minutes=1))
if products
else None
)
try:
result = self._select_orbit(products, dt, dt + datetime.timedelta(minutes=1))
except ValidityError:
result = None
else:
result = None

Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

setuptools.setup(
name="sentineleof",
version="0.6.3",
version="0.6.4",
author="Scott Staniewicz",
author_email="[email protected]",
description="Download precise orbit files for Sentinel 1 products",
Expand Down

0 comments on commit 40b431e

Please sign in to comment.