BUG: Unsorted and Monotonic Indexes respond differently on non-existant key(s) slicing #42331
Labels
Bug
Error Reporting
Incorrect or improved errors from pandas
Indexing
Related to indexing on series/frames, not to indexes themselves
For a python list, bad-indexing can result in
IndexError
:Slicing behaves differently and returns empty list with bad indexes:
For a monotonic
Index
pandas behaves in the same way either when a single key or list of keys is given compared with a slice:For a non-monotonic (unsorted) index the behaviour is the same except for the empty return:
Anyone with ideas?
The text was updated successfully, but these errors were encountered: