Skip to content

Commit 79cab13

Browse files
committed
mypy fixup
1 parent b434c32 commit 79cab13

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

pandas/core/indexing.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2851,7 +2851,10 @@ def infer_and_maybe_downcast(orig: ExtensionArray, new_arr) -> ArrayLike:
28512851

28522852
dtype = orig.dtype
28532853
if isinstance(dtype, NumpyEADtype):
2854-
dtype = dtype.numpy_dtype
2854+
# error: Incompatible types in assignment (expression has
2855+
# type "dtype[Any]", variable has type "ExtensionDtype")
2856+
# [assignment]
2857+
dtype = dtype.numpy_dtype # type: ignore[assignment]
28552858

28562859
if is_np_dtype(new_arr.dtype, "f") and is_np_dtype(dtype, "iu"):
28572860
new_arr = maybe_downcast_to_dtype(new_arr, dtype)

0 commit comments

Comments
 (0)