Skip to content

REF: de-duplicate pointwise get_indexer for IntervalIndex #37919

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
merged 3 commits into from
Nov 18, 2020

Conversation

jbrockmendel
Copy link
Member

No description provided.

@jreback jreback added the Interval Interval data type label Nov 18, 2020
@@ -797,6 +777,30 @@ def get_indexer_non_unique(

return ensure_platform_int(indexer), ensure_platform_int(missing)

def _get_indexer_pointwise(self, target: Index):
Copy link
Contributor

Choose a reason for hiding this comment

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

can add return type

@@ -704,7 +704,7 @@ def get_indexer(

self._check_indexing_method(method)

if self.is_overlapping:
if not self._index_as_unique:
Copy link
Contributor

Choose a reason for hiding this comment

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

i would leave this as it more reading friendly

Copy link
Member Author

Choose a reason for hiding this comment

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

ok. i looked at it and took a minute thinking "wait, why is it different in these two places", thought others might have the same confusion

@jreback jreback added this to the 1.2 milestone Nov 18, 2020
@jreback jreback merged commit 463cd0a into pandas-dev:master Nov 18, 2020
@jbrockmendel jbrockmendel deleted the ref-ii-get_indexer-pointwise branch November 18, 2020 16:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Interval Interval data type
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants