join_asof with strategy="nearest" joins large negative values incorrectly when -inf is present. #20349
Open
2 tasks done
Labels
bug
Something isn't working
needs triage
Awaiting prioritization by a maintainer
python
Related to Python Polars
Checks
Reproducible example
Log output
join parallel: true ASOF join dataframes finished
Issue description
When performing
join_asof
with thenearest
strategy and when-inf
is in the joined column in the left dataframe, values strictly smaller than-(2.0**60)
don't match the nearest value in the joined column of the right dataframe.Expected behavior
I expect
-(2.0**61)
to be considered nearer to0.0
than to1.0
, and thus for the resulting dataframe to be equal topl.DataFrame({"a": [-np.inf, -(2.0**61)], "b": "lower"})
Installed versions
The text was updated successfully, but these errors were encountered: