-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
CLN: remove check_series_type #32513
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
Conversation
this is technically an api change, but not worth leaving it around, but can you add a note in the whatsnew |
(this broke geopandas CI) |
And for subclasses, this keyword can actually be useful. What was the reason you wanted to remove it? |
I'm trying to get rid of the |
How is |
_internal_get_values is called a couple of times in assert_series_equal (more before this PR). Replacing the _internal_get_values usages with e.g. _values is the goal, but it turns out that breaks sometimes when we have Categorical _values. assert_series_equal has several parameters that change the behavior when we have categorical, and I was trying to narrow those down (see also #32527) |
Sorry, that still doesn't explain to me the relation to - if check_series_type:
- # ToDo: There are some tests using rhs is sparse
- # lhs is dense. Should use assert_class_equal in future
- assert isinstance(left, type(right))
- # assert_class_equal(left, right, obj=obj)
+ # TODO: There are some tests using rhs is sparse
+ # lhs is dense. Should use assert_class_equal in future
+ assert isinstance(left, type(right))
+ # assert_class_equal(left, right, obj=obj) so how is that related to (or required by) the |
It isnt related, check_series_type was an innocent bystander that happens to be unused internally. Again, I have no objection if you want to restore it. |
Well, having that the title of the PR didn't give the impression of being an innocent bystander .. ;) (also your "I'm trying to get rid of the |
Trying to clean up assert_series_equal and avoid usage of _internal_get_values; I'm finding that these functions are weird, and in particular categorical dtype handling is opaque