@@ -687,17 +687,8 @@ def value_counts(
687
687
688
688
# multi-index components
689
689
codes = self .grouper .reconstructed_codes
690
- # error: Incompatible types in assignment (expression has type
691
- # "List[ndarray[Any, dtype[_SCT]]]",
692
- # variable has type "List[ndarray[Any, dtype[signedinteger[Any]]]]")
693
- codes = [ # type: ignore[assignment]
694
- rep (level_codes ) for level_codes in codes
695
- ] + [llab (lab , inc )]
696
- # error: List item 0 has incompatible type "Union[ndarray[Any, Any], Index]";
697
- # expected "Index"
698
- levels = [ping .group_index for ping in self .grouper .groupings ] + [
699
- lev # type: ignore[list-item]
700
- ]
690
+ codes = [rep (level_codes ) for level_codes in codes ] + [llab (lab , inc )]
691
+ levels = [ping .group_index for ping in self .grouper .groupings ] + [lev ]
701
692
702
693
if dropna :
703
694
mask = codes [- 1 ] != - 1
@@ -905,8 +896,7 @@ def tshift(self, periods: int = 1, freq=None) -> Series:
905
896
result = self ._op_via_apply ("tshift" , periods = periods , freq = freq )
906
897
return result
907
898
908
- # Decorated property not supported - https://github.com/python/mypy/issues/1362
909
- @property # type: ignore[misc]
899
+ @property
910
900
@doc (Series .plot .__doc__ )
911
901
def plot (self ):
912
902
result = GroupByPlot (self )
@@ -965,15 +955,13 @@ def cov(
965
955
)
966
956
return result
967
957
968
- # Decorated property not supported - https://github.com/python/mypy/issues/1362
969
- @property # type: ignore[misc]
958
+ @property
970
959
@doc (Series .is_monotonic_increasing .__doc__ )
971
960
def is_monotonic_increasing (self ) -> Series :
972
961
result = self ._op_via_apply ("is_monotonic_increasing" )
973
962
return result
974
963
975
- # Decorated property not supported - https://github.com/python/mypy/issues/1362
976
- @property # type: ignore[misc]
964
+ @property
977
965
@doc (Series .is_monotonic_decreasing .__doc__ )
978
966
def is_monotonic_decreasing (self ) -> Series :
979
967
result = self ._op_via_apply ("is_monotonic_decreasing" )
@@ -1012,8 +1000,7 @@ def hist(
1012
1000
)
1013
1001
return result
1014
1002
1015
- # Decorated property not supported - https://github.com/python/mypy/issues/1362
1016
- @property # type: ignore[misc]
1003
+ @property
1017
1004
@doc (Series .dtype .__doc__ )
1018
1005
def dtype (self ) -> Series :
1019
1006
result = self ._op_via_apply ("dtype" )
@@ -2336,7 +2323,7 @@ def tshift(self, periods: int = 1, freq=None, axis: Axis = 0) -> DataFrame:
2336
2323
result = self ._op_via_apply ("tshift" , periods = periods , freq = freq , axis = axis )
2337
2324
return result
2338
2325
2339
- @property # type: ignore[misc]
2326
+ @property
2340
2327
@doc (DataFrame .plot .__doc__ )
2341
2328
def plot (self ) -> GroupByPlot :
2342
2329
result = GroupByPlot (self )
@@ -2407,8 +2394,7 @@ def hist(
2407
2394
)
2408
2395
return result
2409
2396
2410
- # Decorated property not supported - https://github.com/python/mypy/issues/1362
2411
- @property # type: ignore[misc]
2397
+ @property
2412
2398
@doc (DataFrame .dtypes .__doc__ )
2413
2399
def dtypes (self ) -> Series :
2414
2400
result = self ._op_via_apply ("dtypes" )
0 commit comments