Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CLN/BUG: Clean/Simplify _wrap_applied_output #35792

Merged
merged 7 commits into from
Aug 26, 2020

Conversation

rhshadrach
Copy link
Member

  • closes #xxxx
  • tests added / passed
  • passes black pandas
  • passes git diff upstream/master -u -- "*.py" | flake8 --diff
  • whatsnew entry

First part of #35412. I could not find a relevant issue for the test change/whatsnew update.

@rhshadrach rhshadrach added Apply Apply, Aggregate, Transform, Map Bug Clean Groupby labels Aug 18, 2020
@rhshadrach rhshadrach added this to the 1.2 milestone Aug 18, 2020
@rhshadrach
Copy link
Member Author

cc @WillAyd @jbrockmendel @jreback

mac timed out, but otherwise green.

@WillAyd
Copy link
Member

WillAyd commented Aug 19, 2020

/azp run

@azure-pipelines
Copy link
Contributor

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Member

@WillAyd WillAyd left a comment

Choose a reason for hiding this comment

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

lgtm when green

@rhshadrach
Copy link
Member Author

Thanks @WillAyd for restarting the test. Passing now.

Copy link
Contributor

@jreback jreback left a comment

Choose a reason for hiding this comment

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

nice! minor comment. can you run the benchmarks for groupby and report the results to make sure no regressions. ping on green.

pandas/core/groupby/generic.py Show resolved Hide resolved
@pep8speaks
Copy link

pep8speaks commented Aug 20, 2020

Hello @rhshadrach! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻

Comment last updated at 2020-08-26 02:38:15 UTC

…rap_apply_cleanup

� Conflicts:
�	doc/source/whatsnew/v1.2.0.rst
@rhshadrach
Copy link
Member Author

rhshadrach commented Aug 20, 2020

@jreback - comment added; only failures are due to pyarrow.

Edit: Reran Travis, all green now.

@rhshadrach
Copy link
Member Author

Benchmarks ran, no errors, and no significant performance changes.

asv continuous -f 1.1 upstream/master _wrap_apply_cleanup -b ^groupby
...
BENCHMARKS NOT SIGNIFICANTLY CHANGED.

Copy link
Contributor

@jreback jreback left a comment

Choose a reason for hiding this comment

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

small comment, pls rebase and ping on green.

Copy link
Contributor

@jreback jreback left a comment

Choose a reason for hiding this comment

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

minor doc-comment, after fix, merge on green.

@@ -251,6 +251,7 @@ Groupby/resample/rolling
- Bug in :meth:`DataFrameGroupBy.apply` that would some times throw an erroneous ``ValueError`` if the grouping axis had duplicate entries (:issue:`16646`)
- Bug when combining methods :meth:`DataFrame.groupby` with :meth:`DataFrame.resample` and :meth:`DataFrame.interpolate` raising an ``TypeError`` (:issue:`35325`)
- Bug in :meth:`DataFrameGroupBy.apply` where a non-nuisance grouping column would be dropped from the output columns if another groupby method was called before ``.apply()`` (:issue:`34656`)
- Bug in :meth:`DataFrameGroupby.apply` would drop a :class:`CategoricalIndex` when grouped on.
Copy link
Contributor

Choose a reason for hiding this comment

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

can you add the issue number here (in this case use this PR number as there isn't an issue)

@rhshadrach
Copy link
Member Author

/azp run

@azure-pipelines
Copy link
Contributor

Azure Pipelines successfully started running 1 pipeline(s).

@rhshadrach rhshadrach merged commit d90b73b into pandas-dev:master Aug 26, 2020
@rhshadrach rhshadrach deleted the _wrap_apply_cleanup branch August 26, 2020 03:21
@rhshadrach
Copy link
Member Author

Thanks @jreback, merged.

@jbrockmendel
Copy link
Member

@rhshadrach as a rule of thumb, we try not to merge our own PRs

simonjayhawkins pushed a commit to meeseeksmachine/pandas that referenced this pull request Oct 26, 2020
@simonjayhawkins
Copy link
Member

@meeseeksdev backport 1.1.x

This will fail but give instructions

@lumberbot-app

This comment has been minimized.

simonjayhawkins pushed a commit to simonjayhawkins/pandas that referenced this pull request Oct 26, 2020
simonjayhawkins added a commit to meeseeksmachine/pandas that referenced this pull request Oct 26, 2020
simonjayhawkins added a commit that referenced this pull request Oct 26, 2020
…lied_output (#37416)

Co-authored-by: Richard Shadrach <45562402+rhshadrach@users.noreply.github.com>
@simonjayhawkins simonjayhawkins modified the milestones: 1.2, 1.1.4 Oct 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Apply Apply, Aggregate, Transform, Map Bug Clean Groupby
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants