Closed yfa-vagelis closed 2 weeks ago
pandas 2.2.2 is the first version that is compatible with numpy 2.0. I'm not sure how feasible it is to edit the metadata to add in an upper bound on numpy version to an already released version. cc @lithomas1
https://pandas.pydata.org/docs/whatsnew/v2.2.2.html#pandas-2-2-2-is-now-compatible-with-numpy-2-0
We cannot retroactively change packaging metadata on previously released versions. (IIRC, a pin was put in place in time for the pandas 2.1.x series)
You should pin your numpy version to less than 2, or install pandas 2.2.2 as @asishm mentions.
Pinning numpy for future releases of pandas is something that we'll definitely consider (but figuring out which version of numpy to pin to is a non-trivial)
Could you publish another release from the 1.x branch that pins numpy to <2?
Pandas version checks
[X] I have checked that this issue has not already been reported.
[X] I have confirmed this bug exists on the latest version of pandas.
[x] I have confirmed this bug exists on the main branch of pandas.
Reproducible Example
In a clean python 3.11 environment install pandas==2.0.3
This install pandas==2.0.3 and numpy==2.0.0.
Start python and simply import pandas, throws an error