Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some type annotations for coords.py #4294

Draft
wants to merge 5 commits into
base: main
Choose a base branch
from
Draft
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
bounds can be None
rcomer committed Aug 30, 2024
commit d6e7f1b36e56409440646be892ca6837ad4edd27
4 changes: 2 additions & 2 deletions lib/iris/coords.py
Original file line number Diff line number Diff line change
@@ -1591,7 +1591,7 @@ def points(self, points):
self._values = points

@property
def bounds(self) -> RealData:
def bounds(self) -> Optional[RealData]:
"""Coordinate bounds values.

The coordinate bounds values, as a NumPy array,
@@ -1727,7 +1727,7 @@ def core_points(self) -> RealOrLazyData:
"""Core points array at the core of this coord, which may be a NumPy array or a dask array."""
return super()._core_values()

def core_bounds(self) -> RealOrLazyData:
def core_bounds(self) -> Optional[RealOrLazyData]:
"""Core bounds. The points array at the core of this coord, which may be a NumPy array or a dask array."""
result = None
if self.has_bounds():