diff --git a/python-spec/src/somacore/data.py b/python-spec/src/somacore/data.py index a7badfe..b56df7d 100644 --- a/python-spec/src/somacore/data.py +++ b/python-spec/src/somacore/data.py @@ -11,6 +11,7 @@ Any, ClassVar, Iterator, + List, Optional, Sequence, Tuple, @@ -27,6 +28,9 @@ _RO_AUTO = options.ResultOrder.AUTO +AxisDomain = Union[None, Tuple[Any, Any], List[Any]] +Domain = Sequence[AxisDomain] + class DataFrame(base.SOMAObject, metaclass=abc.ABCMeta): """A multi-column table with a user-defined schema. @@ -173,7 +177,7 @@ def read( @abc.abstractmethod def change_domain( self, - newdomain: Optional[Sequence[Optional[Tuple[Any, Any]]]], + newdomain: Domain, check_only: bool = False, ) -> StatusAndReason: """Allows you to enlarge the domain of a SOMA :class:`DataFrame`, when