Skip to content

Conversation

rhshadrach
Copy link
Member

@rhshadrach rhshadrach commented Sep 28, 2022

This reworked test is a bit ghastly, any suggestions on how to simplify or clean up are most welcome.

@rhshadrach rhshadrach added Bug Groupby Regression Functionality that used to work in a prior pandas version NA - MaskedArrays Related to pd.NA and nullable extension arrays labels Sep 28, 2022
@rhshadrach rhshadrach added this to the 1.5.1 milestone Sep 28, 2022
Copy link
Member

@mroeschke mroeschke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wouldn't mind the test be split by dtype (numeric, string, date, category) given the dynamic xfails, and change in scalar values and use of x/y/z to get combos, even if it duplicates the groupby op

@rhshadrach
Copy link
Member Author

Thanks @mroeschke - I was able to simplify this a bit (namely - remove an xfail, less parameters for determining sequence, less repetition of uniques). Also added back in test_series and sparse (thanks for catching that). What do you think - would you still like to see it broken up?

@mroeschke
Copy link
Member

Looks better. There's still a bit to grok to understand range(3**4) -> xyz -> unique values per dtype, but I don't think making it simpler should block the fix.

Copy link
Member

@mroeschke mroeschke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Feel free to merge in a few days to see if anyone else has objection with the test complexity

@mroeschke mroeschke merged commit 8bcc1eb into pandas-dev:main Oct 4, 2022
@mroeschke
Copy link
Member

Thanks @rhshadrach

meeseeksmachine pushed a commit to meeseeksmachine/pandas that referenced this pull request Oct 4, 2022
@rhshadrach rhshadrach deleted the argmax_regr branch October 4, 2022 22:16
phofl pushed a commit that referenced this pull request Oct 5, 2022
… dtypes and dropna=False) (#48938)

Backport PR #48824: REGR: groupby fails with nullable dtypes and dropna=False

Co-authored-by: Richard Shadrach <[email protected]>
noatamir pushed a commit to noatamir/pandas that referenced this pull request Nov 9, 2022
…#48824)

* REGR: groupby fails with nullable dtypes and dropna=False

* Rework test

* Merge cleanup

* Range fixup
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Groupby NA - MaskedArrays Related to pd.NA and nullable extension arrays Regression Functionality that used to work in a prior pandas version
Projects
None yet
Development

Successfully merging this pull request may close these issues.

BUG: pandas 1.5 fails to groupby on (nullable) Int64 column with dropna=False
2 participants