diff --git a/ndcube/utils/wcs.py b/ndcube/utils/wcs.py index 981b8ca0c..a9384bbf3 100644 --- a/ndcube/utils/wcs.py +++ b/ndcube/utils/wcs.py @@ -183,6 +183,10 @@ def _wcs_slicer(wcs, missing_axes, item): new_wcs = wcs.slice(item_checked) # if it a tuple like [0:2, 0:3, 2] or [0:2, 1:3] elif isinstance(item, tuple): + # Ellipsis slicing is currently not supported. + # Raise an error if user tries to slice by ellipsis. + if type(Ellipsis) in [type(item_i) for item_i in item]: + raise NotImplementedError("Slicing FITS-WCS by ellipsis not supported.") # this is used to not exceed the range of the item tuple # if the check of the missing_axes which is False if not dead # is a success than the the item of the tuple is added one by