Skip to content

Commit

Permalink
change to ExhaustiveTypeGuardException error type
Browse files Browse the repository at this point in the history
  • Loading branch information
JessicaS11 committed Oct 29, 2024
1 parent 635e31c commit 130160b
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions icepyx/core/spatial.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
from shapely.geometry import Polygon, box
from shapely.geometry.polygon import orient

import icepyx.core.exceptions

# DevGoal: need to update the spatial_extent docstring to describe coordinate order for input


Expand All @@ -33,10 +35,11 @@ def geodataframe(
If file is False, spatial_extent should be a shapely.Polygon,
list of bounding box coordinates in decimal degrees of [lower-left-longitude,
lower-left-latitute, upper-right-longitude, upper-right-latitude] or polygon vertices as
[longitude1, latitude1, longitude2, latitude2, ... longitude_n,latitude_n, longitude1,latitude1].
[longitude1, latitude1, longitude2, latitude2, ...
longitude_n,latitude_n, longitude1,latitude1].
If file is True, spatial_extent is a string containing the full file path and filename to the
file containing the desired spatial extent.
If file is True, spatial_extent is a string containing the full file path and filename
to the file containing the desired spatial extent.
file :
Indication for whether the spatial_extent string is a filename or coordinate list
Expand Down Expand Up @@ -730,7 +733,7 @@ def fmt_for_CMR(self) -> str:
cmr_extent = ",".join(map(str, extent))

else:
raise RuntimeError("Programmer error!")
raise icepyx.core.exceptions.ExhaustiveTypeGuardException

return cmr_extent

Expand Down

0 comments on commit 130160b

Please sign in to comment.