You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug]: -2**63 // -1 inconsistent across backends, SQLFrame silently returns a float #4071
The value -2**63 // -1 overflows int64, which backends handle in different ways. Polars, pandas and Dask wrap around to -2**63. pyarrow and DuckDB raise an overflow error, and ibis raises a conversion error. Finally, SQLFrame returns 9.223372036854776e+18 as a float with no error.
I think the SQLFrame one is the result I'd worry about most, since it's silently wrong.
Steps or code to reproduce the bug
Simply running a file like this is enough to see the bug:
I'm not sure which behaviour narwhals is expected to adhere to here. Wrapping would match Polars, and raising is what pyarrow and DuckDB do. But either way SQLFrame shouldn't be returning a float.
changed the title [-][Bug]: '-2**63 // -1' inconsistent across backends, SQLFrame silently returns a float[/-][+][Bug]: `-2**63 // -1` inconsistent across backends, SQLFrame silently returns a float[/+]on Oct 13, 2026
Activity
[-][Bug]: '-2**63 // -1' inconsistent across backends, SQLFrame silently returns a float[/-][+][Bug]: `-2**63 // -1` inconsistent across backends, SQLFrame silently returns a float[/+]