-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
BUG: duplicate indexing on non-integer index with positional indexers failing in py3 #13427
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
Comments
Just as an update - it happens to work on Python 2.7.11/Pandas 0.18.1 on Windows as well. |
The root example is here: This works in py2
We explicity catch the unordered exception and raise an error break out of the indexing code, but not sure what is happening after. This should work. |
What you are writing is very fragile code anyhow, using getitem depends on the index, which in this case doesn't work (as they are strings), using
|
Removing the |
this is now fixed on master
|
fixed in #29700 7eb0db3 is the first new commit
|
Code Sample, a copy-pastable example if possible
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\Alexander\Anaconda3\lib\site-packages\pandas\core\frame.py", line 4061, in apply
return self._apply_standard(f, axis, reduce=reduce)
File "C:\Users\Alexander\Anaconda3\lib\site-packages\pandas\core\frame.py", line 4157, in _apply_standard
results[i] = func(v)
File "", line 1, in
File "C:\Users\Alexander\Anaconda3\lib\site-packages\pandas\core\series.py", line 583, in getitem
result = self.index.get_value(self, key)
File "C:\Users\Alexander\Anaconda3\lib\site-packages\pandas\indexes\base.py", line 2000, in get_value
raise IndexError(key)
IndexError: (0, 'occurred at index 0')
This is the error I get when running on Python 3.5.1/Pandas 0.18.1 on Windows. I get the expected output on Linux running Python 2.7.11/Pandas 0.18.1.
The text was updated successfully, but these errors were encountered: