You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@sedona.apache.org by "jiayuasu (via GitHub)" <gi...@apache.org> on 2026/10/22 16:00:05 UTC
[PR] fix(python/sedonadb-geopandas): multiply and divide durations by integral floats exactly [sedona-db]
jiayuasu opened a new pull request, #1482:
URL: https://github.com/apache/sedona-db/pull/1482
## What changes
The Python CI now installs pandas 3.1.0, which multiplies and divides a timedelta by an integral-valued float (`3.0`) exactly, as it does by the same integer, where earlier versions computed it in float64. Above 2**53 ticks the two differ: `Timedelta(2**53 + 1) * 3.0` is `...979` in pandas 3.1 and `...976` in float64. `sedonadb-geopandas` deliberately reproduced the float64 result (only the identities `±1.0` were exact), and `test_non_identity_float_duration_arithmetic_matches_pandas` compared it against the installed pandas, so it now fails on `main` (after #1481 fixed the DuckDB failures).
An integral-valued float within the 64-bit tick range now takes the exact integer path, as an integer does: correct in every version, and what pandas does as of 3.1. One past the range (`1e30`) stays on the float path, whose range check raises, as pandas raises for it. Other floats still compute in float64, as in pandas.
## Testing
The test now compares integral floats against pandas' result for the same integer (exact in every pandas version) and other floats against pandas directly. The suite passes with pandas 2.3, 3.0, and 3.1; `main`'s code fails this test on 3.1.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@sedona.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] fix(python/sedonadb-geopandas): multiply and divide durations by integral floats exactly [sedona-db]
Posted by "jiayuasu (via GitHub)" <gi...@apache.org>.
jiayuasu merged PR #1482:
URL: https://github.com/apache/sedona-db/pull/1482
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@sedona.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org