Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Comparison for Array and List with masked out values is wrong when broadcasting #20165

Closed
2 tasks done
coastalwhite opened this issue Dec 5, 2024 · 0 comments · Fixed by #20243
Closed
2 tasks done
Assignees
Labels
A-dtype-list/array Area: list/array data type accepted Ready for implementation bug Something isn't working P-high Priority: high python Related to Python Polars

Comments

@coastalwhite
Copy link
Collaborator

Checks

  • I have checked that this issue has not already been reported.
  • I have confirmed this bug exists on the latest version of Polars.

Reproducible example

import polars as pl
import io
s = pl.Series('a', [None, [None]], pl.List(pl.Int64)) # Alternatively pl.Array(pl.Int64, 1)
filt = pl.Series('f', [False, True])

df = pl.DataFrame([ s, filt ])

concatted_df = pl.concat([df[:1], df[1:]])

print(df.with_row_index().filter(pl.col.f))
print(concatted_df.with_row_index().filter(pl.col.f))

df.with_row_index().filter(pl.col.f).equals(concatted_df.with_row_index().filter(pl.col.f))

Log output

False

Issue description

.

Expected behavior

.

Installed versions

Replace this line with the output of pl.show_versions(). Leave the backticks in place.
@coastalwhite coastalwhite added bug Something isn't working python Related to Python Polars needs triage Awaiting prioritization by a maintainer labels Dec 5, 2024
GertABB added a commit to GertABB/polars that referenced this issue Dec 5, 2024
@nameexhaustion nameexhaustion self-assigned this Dec 10, 2024
@nameexhaustion nameexhaustion changed the title Comparison for Array and List with masked out values is wrong Comparison for Array and List with masked out values is wrong when broadcasting Dec 10, 2024
@nameexhaustion nameexhaustion added P-high Priority: high A-dtype-list/array Area: list/array data type and removed needs triage Awaiting prioritization by a maintainer labels Dec 10, 2024
@github-project-automation github-project-automation bot moved this to Ready in Backlog Dec 10, 2024
@github-project-automation github-project-automation bot moved this from Ready to Done in Backlog Dec 10, 2024
@c-peters c-peters added the accepted Ready for implementation label Dec 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-dtype-list/array Area: list/array data type accepted Ready for implementation bug Something isn't working P-high Priority: high python Related to Python Polars
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants