-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Open
Description
Describe the enhancement requested
New warnings are appearing with pytest and doctest:
/opt/conda/envs/arrow/lib/python3.11/site-packages/pyarrow/interchange/from_dataframe.py:113: Pandas4Warning: The Dataframe Interchange Protocol is deprecated.
For dataframe-agnostic code, you may want to look into:
- Arrow PyCapsule Interface: https://arrow.apache.org/docs/format/CDataInterface/PyCapsuleInterface.html
- Narwhals: https://github.com/narwhals-dev/narwhals
return _from_dataframe(df.__dataframe__(allow_copy=allow_copy),due to Pandas moving the dataframe interchange protocol out of the repo in the next major release (4.0.0), see:
- warnings in doctest: https://github.com/apache/arrow/actions/runs/23557627928/job/68588688057?pr=49377#step:6:4433
- warning in pytest: https://github.com/apache/arrow/actions/runs/23557627928/job/68588688057?pr=49377#step:6:4392
- pandas deprecation issue: Move interchange protocol implementation into a separate project pandas-dev/pandas#56732
Two things that come to mind:
- for the time being, which library to use in the conversion tests and documentation examples? Maybe Polars? @jorisvandenbossche I am not sure if there is a plan to have a separate pandas interchange package or that was just an initial idea and pandas plans to completely move away from the protocol?
- How long to keep the implementation of the protocol in PyArrow. I think we should maintain it for a while. There has been not much of maintainance burden so far. The only problem is that feature requests are stuck due to the dataframe interchange protocol project being idle.
Component(s)
Python
Reactions are currently unavailable