Skip to content

Commit 368646d

Browse files
committed
mypy fixup
1 parent ec4e3aa commit 368646d

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

pandas/core/missing.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,12 +102,14 @@ def mask_missing(arr: ArrayLike, value) -> npt.NDArray[np.bool_]:
102102
if arr.dtype.kind == "f":
103103
# GH#55127
104104
if isinstance(arr.dtype, BaseMaskedDtype):
105-
mask = np.isnan(arr._data) & ~arr.isna()
105+
# error: "ExtensionArray" has no attribute "_data" [attr-defined]
106+
mask = np.isnan(arr._data) & ~arr.isna() # type: ignore[attr-defined,operator]
106107
return mask
107108
else:
109+
# error: "ExtensionArray" has no attribute "_pa_array" [attr-defined]
108110
import pyarrow.compute as pc
109111

110-
mask = pc.is_nan(arr._pa_array).fill_null(False).to_numpy()
112+
mask = pc.is_nan(arr._pa_array).fill_null(False).to_numpy() # type: ignore[attr-defined]
111113
return mask
112114

113115
elif arr.dtype.kind in "iu":

0 commit comments

Comments
 (0)