-
-
Notifications
You must be signed in to change notification settings - Fork 18.1k
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
BUG: Subtraction fails with matching index of different name and type #57524
Comments
Thanks for the report. Might be related to #45564 - cc @phofl. Lines 4637 to 4646 in 9530851
Prior to this PR, we would not call pandas/pandas/core/array_algos/take.py Lines 127 to 129 in 9530851
but no such logic exists for EAs. Perhaps it should? |
take |
1 similar comment
take |
take |
2 similar comments
take |
take |
…ferent-name-and-type-pandas-dev#57524
…ferent-name-and-type-pandas-dev#57524
Pandas version checks
I have checked that this issue has not already been reported.
I have confirmed this bug exists on the latest version of pandas.
I have confirmed this bug exists on the main branch of pandas.
Reproducible Example
Issue Description
This example with two series with a nullable integer data type and a index with different names and of differing data types, on with a nullable string datatype and object datatype fails with and error from
pandas._libs.algos.ensure_platform_int()
If any of these three conditions is removed, the subtraction succeeds.
Expected Behavior
The subtraction should succeed.
Installed Versions
commit: 2a953cf
python: 3.10.9.final.0
python-bits : 64
OS : Linux
OS-release : 5.15.133+
Version : #1 SMP Sat Dec 30 11:18:04 UTC 2023
machine : x86_64
processor : x86_64
byteorder : little
LC_ALL : en_US.UTF-8
LANG : en_US.UTF-8
LOCALE : en_US.UTF-8
pandas : 2.1.3
numpy : 1.24.4
pytz : 2023.3.post1
dateutil : 2.8.2
setuptools : 69.0.3
pip : 23.2.1
Cython : None
pytest : 7.4.4
hypothesis : 6.91.0
sphinx : None
blosc : None
feather : None
xlsxwriter : None
lxml.etree : 5.0.0
html5lib : None
pymysql : None
psycopg2 : None
jinja2 : 3.1.2
IPython : 8.19.0
pandas_datareader : None
bs4 : 4.12.2
bottleneck : None
dataframe-api-compat: None
fastparquet : None
fsspec : 2023.12.2
gcsfs : 2023.12.2post1
matplotlib : 3.8.2
numba : 0.57.1
numexpr : None
odfpy : None
openpyxl : None
pandas_gbq : None
pyarrow : 13.0.0
pyreadstat : None
pyxlsb : None
s3fs : None
scipy : 1.11.4
sqlalchemy : 2.0.24
tables : None
tabulate : None
xarray : 2023.8.0
xlrd : None
zstandard : None
tzdata : 2023.4
qtpy : None
pyqt5 : None
The text was updated successfully, but these errors were encountered: