Skip to content

Commit 290c5f4

Browse files
committed
TYP: use Shape alias in core/internals/managers.py
1 parent 66b9095 commit 290c5f4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

pandas/core/internals/managers.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
import numpy as np
1818

1919
from pandas._libs import internals as libinternals, lib
20-
from pandas._typing import ArrayLike, DtypeObj, Label
20+
from pandas._typing import ArrayLike, DtypeObj, Label, Shape
2121
from pandas.util._validators import validate_bool_kwarg
2222

2323
from pandas.core.dtypes.cast import (
@@ -204,7 +204,7 @@ def __nonzero__(self) -> bool:
204204
__bool__ = __nonzero__
205205

206206
@property
207-
def shape(self) -> Tuple[int, ...]:
207+
def shape(self) -> Shape:
208208
return tuple(len(ax) for ax in self.axes)
209209

210210
@property
@@ -1825,7 +1825,7 @@ def _asarray_compat(x):
18251825
else:
18261826
return np.asarray(x)
18271827

1828-
def _shape_compat(x):
1828+
def _shape_compat(x) -> Shape:
18291829
if isinstance(x, ABCSeries):
18301830
return (len(x),)
18311831
else:

0 commit comments

Comments
 (0)