Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

BUG: Joining Pandas with Polars dataframe produces fuzzy errormessage #61434

Open
Labels
BugError ReportingIncorrect or improved errors from pandas
@Juan-132

Description

@Juan-132

Pandas version checks

  • I have checked that this issue has not already been reported.

  • I have confirmed this bug exists on thelatest version of pandas.

  • I have confirmed this bug exists on themain branch of pandas.

Reproducible Example

Seebelow.

Issue Description

Reproducible example

importpandasaspddata= {"Column2": [10,20,30],"Column3": ["A","B","C"],"Column4": ["Lala","YesYes","NoNo"],}df1=pd.DataFrame(data)
importpolarsaspldata= {"Column1": ["Text1","Text2","Text3"],"Column2": [10,20,30],"Column3": ["A","B","C"]}df2=pl.DataFrame(data)
result=df1.join(df2,on=["Column2","Column3"],how="inner")

Log output

---------------------------------------------------------------------------ValueError                                Traceback (most recent call last)~\AppData\Local\Temp\ipykernel_11612\367032622.pyin?()----> 1 result = df1.join(df2, on=["Column2","Column3"], how="inner")c:\Users\name\AppData\Local\Programs\Python\Python312\Lib\site-packages\pandas\core\frame.pyin?(self, other, on, how, lsuffix, rsuffix, sort, validate)  10766                 validate=validate,  10767             )  10768         else:  10769if on is not None:> 10770                 raise ValueError(  10771"Joining multiple DataFrames only supported for joining on index"  10772                 )  10773 ValueError: Joining multiple DataFrames only supportedfor joining on index

Expected Behavior

Expected Result
Error message is not correct.
It should say that joining pandas dataframe with polars dataframe is not supported.

This is how Polars formulates the error when joining the other way around:
TypeError: expectedother join table to be a DataFrame, not 'pandas.core.frame.DataFrame'

Installed Versions

INSTALLED VERSIONS

commit :0691c5c
python : 3.12.9
python-bits : 64
OS : Windows
OS-release : 10
Version : 10.0.19045
machine : AMD64
processor : Intel64 Family 6 Model 140 Stepping 1, GenuineIntel
byteorder : little
LC_ALL : None
LANG : None
LOCALE : Dutch_Netherlands.1252

pandas : 2.2.3
numpy : 2.2.5
pytz : 2025.2
dateutil : 2.9.0.post0
pip : 25.1.1
Cython : None
sphinx : None
IPython : 9.2.0
adbc-driver-postgresql: None
...
zstandard : None
tzdata : 2025.2
qtpy : None
pyqt5 : None

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugError ReportingIncorrect or improved errors from pandas

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp