forked from pola-rs/polars
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: Divide
ChunkCompare
into Eq
and Ineq
variants
Divide the `ChunkCompare` trait into two traits `ChunkCompareEq` and `ChunkCompareIneq`, which allows us to statistically verify that there are no calls to the inequality methods when these are not available (e.g. for `List`, `Array` and `Struct`). This makes error handling a lot better as well. For example, the following was a panic exception before. ```python import polars as pl a = pl.Series('a', [[1]], pl.Array(pl.Int8, 1)) b = pl.Series('b', [[1]], pl.Array(pl.Int8, 1)) c = a < b ``` Now, it returns: ``` polars.exceptions.InvalidOperationError: cannot perform '<' comparison between series 'a' of dtype: array[i8, 1] and series 'b' of dtype: array[i8, 1] ``` Fixes pola-rs#18938.
- Loading branch information
1 parent
d097d3c
commit 7bab314
Showing
13 changed files
with
262 additions
and
158 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.