-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
DatetimeIndex._maybe_cast_slice_bound with duplicates #16515
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
Labels
Milestone
Comments
Actually, we don't need any additional cython code. We can just do @property
def is_strictly_monotonically_increasing(self):
return self.is_unique and self.is_monotonic_increasing Do we want to add that as a method? I'm slightly in favor of adding it. |
@TomAugspurger yeah that sound fine (add tests as well), do this in base and it should just work for all Index sub-classes (maybe add is_strictly_monotonicaly_decreasing as well) |
TomAugspurger
added a commit
to TomAugspurger/pandas
that referenced
this issue
May 31, 2017
Fixed an edge case in partial string indexing where we would incorrectly flip the endpoint on a slice, since we checked for monotonicity when we needed strict monotonicity. Closes pandas-dev#16515 xref dask/dask#2389
TomAugspurger
added a commit
to TomAugspurger/pandas
that referenced
this issue
May 31, 2017
Fixed an edge case in partial string indexing where we would incorrectly flip the endpoint on a slice, since we checked for monotonicity when we needed strict monotonicity. Closes pandas-dev#16515 xref dask/dask#2389
Merged
TomAugspurger
added a commit
to TomAugspurger/pandas
that referenced
this issue
May 31, 2017
Fixed an edge case in partial string indexing where we would incorrectly flip the endpoint on a slice, since we checked for monotonicity when we needed strict monotonicity. Closes pandas-dev#16515 xref dask/dask#2389
TomAugspurger
added a commit
to TomAugspurger/pandas
that referenced
this issue
May 31, 2017
Fixed an edge case in partial string indexing where we would incorrectly flip the endpoint on a slice, since we checked for monotonicity when we needed strict monotonicity. Closes pandas-dev#16515 xref dask/dask#2389
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
DatetimeIndex._maybe_cast_slice_bound
can return the wrong value when you have an index that is monotonically decreasing, but not strictly monotonically decreasing.The issue is here That check really needs to check for strict monotonic decreasing, not just monotonic decreasing.
Have we hit any other needs for strict monotonic algos? This is such an extreme edge case, not sure it's worthwhile on its own.
Came up in dask/dask#2389
The text was updated successfully, but these errors were encountered: