Skip to content

CLN: remove unused categories/ordered handling in astype #28646

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

Merged

Conversation

jorisvandenbossche
Copy link
Member

This removes some unused code in the internals astype. There is a small change in behaviour though, when passing the categories/ordered keyword you now get TypeError instead of ValueError. But since that is Python's default behaviour, I would say this is rather a good fix.

@jbrockmendel
Copy link
Member

jbrockmendel commented Sep 26, 2019

No opinion on the TypeError vs ValueError. Looks like a nice cleanup.

@topper-123
Copy link
Contributor

Shouldn't this get an entry in the whatsnew ("Removal of prior version deprecations/changes"). else no comment.

@topper-123 topper-123 added Clean Dtype Conversions Unexpected or buggy dtype conversions labels Sep 26, 2019
@jorisvandenbossche
Copy link
Member Author

Shouldn't this get an entry in the whatsnew ("Removal of prior version deprecations/changes").

It was already removed before. It was only not "fully" removed, and instead of just removing kwargs, we explicitly raised an error if categories or ordered was passed as a kwarg (instead of relying on python to raise that error).

@jreback jreback added this to the 1.0 milestone Sep 27, 2019
@jreback
Copy link
Contributor

jreback commented Sep 27, 2019

lgtm. thanks @jorisvandenbossche

@jreback jreback merged commit 667c947 into pandas-dev:master Sep 27, 2019
@jorisvandenbossche jorisvandenbossche deleted the cln-categorical-astype branch September 27, 2019 14:58
josibake pushed a commit to josibake/pandas that referenced this pull request Sep 29, 2019
proost pushed a commit to proost/pandas that referenced this pull request Dec 19, 2019
proost pushed a commit to proost/pandas that referenced this pull request Dec 19, 2019
bongolegend pushed a commit to bongolegend/pandas that referenced this pull request Jan 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Clean Dtype Conversions Unexpected or buggy dtype conversions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants