File tree Expand file tree Collapse file tree 2 files changed +8
-7
lines changed Expand file tree Collapse file tree 2 files changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -2832,18 +2832,17 @@ def blk_func(values: ArrayLike) -> ArrayLike:
28322832 else :
28332833 # We broadcast algorithms.take_nd analogous to
28342834 # np.take_along_axis
2835-
2836- # Note: we only get here with backfill/pad,
2837- # so if we have a dtype that cannot hold NAs,
2838- # then there will be no -1s in indexer, so we can use
2839- # the original dtype (no need to ensure_dtype_can_hold_na)
28402835 if isinstance (values , np .ndarray ):
28412836 dtype = values .dtype
28422837 if self .grouper .has_dropped_na :
28432838 # dropped null groups give rise to nan in the result
28442839 dtype = ensure_dtype_can_hold_na (values .dtype )
28452840 out = np .empty (values .shape , dtype = dtype )
28462841 else :
2842+ # Note: we only get here with backfill/pad,
2843+ # so if we have a dtype that cannot hold NAs,
2844+ # then there will be no -1s in indexer, so we can use
2845+ # the original dtype (no need to ensure_dtype_can_hold_na)
28472846 out = type (values )._empty (values .shape , dtype = values .dtype )
28482847
28492848 for i , value_element in enumerate (values ):
Original file line number Diff line number Diff line change 44
55import inspect
66
7+ import pytest
8+
79from pandas import (
810 DataFrame ,
911 Series ,
1719def test_frame_consistency (groupby_func ):
1820 # GH#48028
1921 if groupby_func in ("first" , "last" ):
20- # first and last are entirely different between frame and groupby
21- return
22+ msg = " first and last are entirely different between frame and groupby"
23+ pytest . skip ( reason = msg )
2224
2325 if groupby_func in ("cumcount" , "ngroup" ):
2426 assert not hasattr (DataFrame , groupby_func )
You can’t perform that action at this time.
0 commit comments