Skip to content

Commit 3012424

Browse files
committed
Removed type ignores
1 parent 3bd4425 commit 3012424

File tree

5 files changed

+5
-20
lines changed

5 files changed

+5
-20
lines changed

pandas/core/computation/ops.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,7 @@
7676
class Term:
7777
def __new__(cls, name, env, side=None, encoding=None):
7878
klass = Constant if not isinstance(name, str) else cls
79-
# error: Argument 2 for "super" not an instance of argument 1
80-
supr_new = super(Term, klass).__new__ # type: ignore[misc]
79+
supr_new = super(Term, klass).__new__
8180
return supr_new(klass)
8281

8382
is_local: bool

pandas/core/missing.py

+1-7
Original file line numberDiff line numberDiff line change
@@ -413,13 +413,7 @@ def func(yvalues: np.ndarray) -> None:
413413
**kwargs,
414414
)
415415

416-
# error: Argument 1 to "apply_along_axis" has incompatible type
417-
# "Callable[[ndarray[Any, Any]], None]"; expected "Callable[...,
418-
# Union[_SupportsArray[dtype[<nothing>]], Sequence[_SupportsArray
419-
# [dtype[<nothing>]]], Sequence[Sequence[_SupportsArray[dtype[<nothing>]]]],
420-
# Sequence[Sequence[Sequence[_SupportsArray[dtype[<nothing>]]]]],
421-
# Sequence[Sequence[Sequence[Sequence[_SupportsArray[dtype[<nothing>]]]]]]]]"
422-
np.apply_along_axis(func, axis, data) # type: ignore[arg-type]
416+
np.apply_along_axis(func, axis, data)
423417

424418

425419
def _index_to_interp_indices(index: Index, method: str) -> np.ndarray:

pandas/io/common.py

+1-3
Original file line numberDiff line numberDiff line change
@@ -910,10 +910,8 @@ def get_handle(
910910
or not hasattr(handle, "seekable")
911911
):
912912
handle = _IOWrapper(handle)
913-
# error: Argument 1 to "TextIOWrapper" has incompatible type
914-
# "_IOWrapper"; expected "IO[bytes]"
915913
handle = TextIOWrapper(
916-
handle, # type: ignore[arg-type]
914+
handle,
917915
encoding=ioargs.encoding,
918916
errors=errors,
919917
newline="",

pandas/plotting/_matplotlib/boxplot.py

+1-4
Original file line numberDiff line numberDiff line change
@@ -198,10 +198,7 @@ def _make_plot(self, fig: Figure) -> None:
198198
else self.data
199199
)
200200

201-
# error: Argument "data" to "_iter_data" of "MPLPlot" has
202-
# incompatible type "object"; expected "DataFrame |
203-
# dict[Hashable, Series | DataFrame]"
204-
for i, (label, y) in enumerate(self._iter_data(data=data)): # type: ignore[arg-type]
201+
for i, (label, y) in enumerate(self._iter_data(data=data)):
205202
ax = self._get_ax(i)
206203
kwds = self.kwds.copy()
207204

pandas/plotting/_matplotlib/hist.py

+1-4
Original file line numberDiff line numberDiff line change
@@ -137,10 +137,7 @@ def _make_plot(self, fig: Figure) -> None:
137137
if self.by is not None
138138
else self.data
139139
)
140-
141-
# error: Argument "data" to "_iter_data" of "MPLPlot" has incompatible
142-
# type "object"; expected "DataFrame | dict[Hashable, Series | DataFrame]"
143-
for i, (label, y) in enumerate(self._iter_data(data=data)): # type: ignore[arg-type]
140+
for i, (label, y) in enumerate(self._iter_data(data=data)):
144141
ax = self._get_ax(i)
145142

146143
kwds = self.kwds.copy()

0 commit comments

Comments
 (0)