@@ -890,7 +890,7 @@ def style(self) -> "Styler":
890890 """
891891
892892 @Appender (_shared_docs ["items" ])
893- def items (self ) -> Iterable [Tuple [Optional [ Hashable ] , Series ]]:
893+ def items (self ) -> Iterable [Tuple [Label , Series ]]:
894894 if self .columns .is_unique and hasattr (self , "_item_cache" ):
895895 for k in self .columns :
896896 yield k , self ._get_item_cache (k )
@@ -899,10 +899,10 @@ def items(self) -> Iterable[Tuple[Optional[Hashable], Series]]:
899899 yield k , self ._ixs (i , axis = 1 )
900900
901901 @Appender (_shared_docs ["items" ])
902- def iteritems (self ) -> Iterable [Tuple [Optional [ Hashable ] , Series ]]:
902+ def iteritems (self ) -> Iterable [Tuple [Label , Series ]]:
903903 yield from self .items ()
904904
905- def iterrows (self ) -> Iterable [Tuple [Optional [ Hashable ] , Series ]]:
905+ def iterrows (self ) -> Iterable [Tuple [Label , Series ]]:
906906 """
907907 Iterate over DataFrame rows as (index, Series) pairs.
908908
@@ -4043,7 +4043,7 @@ def set_index(
40434043 "one-dimensional arrays."
40444044 )
40454045
4046- missing : List [Optional [ Hashable ] ] = []
4046+ missing : List [Label ] = []
40474047 for col in keys :
40484048 if isinstance (
40494049 col , (ABCIndexClass , ABCSeries , np .ndarray , list , abc .Iterator )
@@ -4082,7 +4082,7 @@ def set_index(
40824082 else :
40834083 arrays .append (self .index )
40844084
4085- to_remove : List [Optional [ Hashable ] ] = []
4085+ to_remove : List [Label ] = []
40864086 for col in keys :
40874087 if isinstance (col , ABCMultiIndex ):
40884088 for n in range (col .nlevels ):
@@ -4137,7 +4137,7 @@ def reset_index(
41374137 drop : bool = False ,
41384138 inplace : bool = False ,
41394139 col_level : Hashable = 0 ,
4140- col_fill : Optional [ Hashable ] = "" ,
4140+ col_fill : Label = "" ,
41414141 ) -> Optional ["DataFrame" ]:
41424142 """
41434143 Reset the index, or a level of it.
0 commit comments