@@ -1653,14 +1653,9 @@ def to_string(
1653
1653
return result
1654
1654
else :
1655
1655
if hasattr (buf , "write" ):
1656
- # error: Item "str" of "Union[str, PathLike[str], WriteBuffer
1657
- # [str]]" has no attribute "write"
1658
- buf .write (result ) # type: ignore[union-attr]
1656
+ buf .write (result )
1659
1657
else :
1660
- # error: Argument 1 to "open" has incompatible type "Union[str,
1661
- # PathLike[str], WriteBuffer[str]]"; expected "Union[Union[str,
1662
- # bytes, PathLike[str], PathLike[bytes]], int]"
1663
- with open (buf , "w" ) as f : # type: ignore[arg-type]
1658
+ with open (buf , "w" ) as f :
1664
1659
f .write (result )
1665
1660
return None
1666
1661
@@ -4406,8 +4401,9 @@ def any(
4406
4401
) -> Series | bool :
4407
4402
...
4408
4403
4404
+ # error: Missing return statement
4409
4405
@doc (NDFrame .any , ** _shared_doc_kwargs )
4410
- def any (
4406
+ def any ( # type: ignore[empty-body]
4411
4407
self ,
4412
4408
axis : Axis = 0 ,
4413
4409
bool_only : bool | None = None ,
@@ -5015,9 +5011,8 @@ def fillna(
5015
5011
) -> Series | None :
5016
5012
...
5017
5013
5018
- # error: Signature of "fillna" incompatible with supertype "NDFrame"
5019
5014
@doc (NDFrame .fillna , ** _shared_doc_kwargs )
5020
- def fillna ( # type: ignore[override]
5015
+ def fillna (
5021
5016
self ,
5022
5017
value : Hashable | Mapping | Series | DataFrame = None ,
5023
5018
* ,
@@ -5090,14 +5085,13 @@ def replace(
5090
5085
) -> None :
5091
5086
...
5092
5087
5093
- # error: Signature of "replace" incompatible with supertype "NDFrame"
5094
5088
@doc (
5095
5089
NDFrame .replace ,
5096
5090
klass = _shared_doc_kwargs ["klass" ],
5097
5091
inplace = _shared_doc_kwargs ["inplace" ],
5098
5092
replace_iloc = _shared_doc_kwargs ["replace_iloc" ],
5099
5093
)
5100
- def replace ( # type: ignore[override]
5094
+ def replace (
5101
5095
self ,
5102
5096
to_replace = None ,
5103
5097
value = lib .no_default ,
0 commit comments