Skip to content

Commit e0a8dca

Browse files
committed
remove irrelevant changes
1 parent 3894785 commit e0a8dca

File tree

2 files changed

+12
-47
lines changed

2 files changed

+12
-47
lines changed

pandas-stubs/core/base.pyi

Lines changed: 0 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ from pandas._libs.tslibs.timedeltas import Timedelta
2929
from pandas._typing import (
3030
S1,
3131
S2,
32-
S3,
3332
AxisIndex,
3433
DropKeep,
3534
DTypeLike,
@@ -323,30 +322,6 @@ class ElementOpsMixin(Generic[S2]):
323322
def _proto_rfloordiv(
324323
self: ElementOpsMixin[Timedelta], other: timedelta | np.timedelta64 | Timedelta
325324
) -> ElementOpsMixin[int]: ...
326-
@overload
327-
def _proto_mod(
328-
self: ElementOpsMixin[int], other: int | np.integer
329-
) -> ElementOpsMixin[int]: ...
330-
@overload
331-
def _proto_mod(
332-
self: ElementOpsMixin[float], other: float | np.floating
333-
) -> ElementOpsMixin[float]: ...
334-
@overload
335-
def _proto_mod(
336-
self: ElementOpsMixin[Timedelta], other: timedelta | np.timedelta64 | Timedelta
337-
) -> ElementOpsMixin[Timedelta]: ...
338-
@overload
339-
def _proto_rmod(
340-
self: ElementOpsMixin[int], other: int | np.integer
341-
) -> ElementOpsMixin[int]: ...
342-
@overload
343-
def _proto_rmod(
344-
self: ElementOpsMixin[float], other: float | np.floating
345-
) -> ElementOpsMixin[float]: ...
346-
@overload
347-
def _proto_rmod(
348-
self: ElementOpsMixin[Timedelta], other: timedelta | np.timedelta64 | Timedelta
349-
) -> ElementOpsMixin[Timedelta]: ...
350325

351326
@type_check_only
352327
class Supports_ProtoAdd(Protocol[_T_contra, S2]):
@@ -379,21 +354,3 @@ class Supports_ProtoFloorDiv(Protocol[_T_contra, S2]):
379354
@type_check_only
380355
class Supports_ProtoRFloorDiv(Protocol[_T_contra, S2]):
381356
def _proto_rfloordiv(self, other: _T_contra, /) -> ElementOpsMixin[S2]: ...
382-
383-
@type_check_only
384-
class Supports_ProtoMod(Protocol[_T_contra, S2]):
385-
def _proto_mod(self, other: _T_contra, /) -> ElementOpsMixin[S2]: ...
386-
387-
@type_check_only
388-
class Supports_ProtoRMod(Protocol[_T_contra, S2]):
389-
def _proto_rmod(self, other: _T_contra, /) -> ElementOpsMixin[S2]: ...
390-
391-
@type_check_only
392-
class Supports_ProtoDivMod(Protocol[_T_contra, S2, S3]):
393-
def _proto_floordiv(self, other: _T_contra, /) -> ElementOpsMixin[S2]: ...
394-
def _proto_mod(self, other: _T_contra, /) -> ElementOpsMixin[S3]: ...
395-
396-
@type_check_only
397-
class Supports_ProtoRDivMod(Protocol[_T_contra, S2, S3]):
398-
def _proto_rfloordiv(self, other: _T_contra, /) -> ElementOpsMixin[S2]: ...
399-
def _proto_rmod(self, other: _T_contra, /) -> ElementOpsMixin[S3]: ...

tests/test_natype.py

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,11 @@ def test_arithmetic() -> None:
8383
# __divmod__
8484
# bug upstream: https://github.com/pandas-dev/pandas/issues/62196
8585
# check(
86-
assert_type(divmod(na, s_int), tuple[pd.Series, pd.Series])
87-
# , tuple
86+
# assert_type(
87+
# divmod(na, s_int),
88+
# tuple[pd.Series, pd.Series],
89+
# ),
90+
# tuple,
8891
# )
8992
# check(
9093
# assert_type(
@@ -107,8 +110,13 @@ def test_arithmetic() -> None:
107110
# __rdivmod__
108111
# bug upstream: https://github.com/pandas-dev/pandas/issues/62196
109112
# check(
110-
assert_type(divmod(s_int, na), "tuple[pd.Series[int], pd.Series[int]]")
111-
# , tuple,
113+
# assert_type(divmod(s_int, na), tuple[pd.Series, pd.Series]),
114+
# tuple,
115+
# )
116+
# https://github.com/pandas-dev/pandas-stubs/issues/1347
117+
# check(
118+
# assert_type(divmod(idx_int, na), tuple[pd.Index, pd.Index]),
119+
# tuple, # , tuple,
112120
# )
113121
# bug upstream: https://github.com/pandas-dev/pandas/issues/62196
114122
# check(

0 commit comments

Comments
 (0)