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

Incorrect select(len()) with some select orderings #20220

Closed
2 tasks done
nameexhaustion opened this issue Dec 9, 2024 · 0 comments · Fixed by #20222 or #20223
Closed
2 tasks done

Incorrect select(len()) with some select orderings #20220

nameexhaustion opened this issue Dec 9, 2024 · 0 comments · Fixed by #20222 or #20223
Assignees
Labels
A-optimizer Area: plan optimization accepted Ready for implementation bug Something isn't working python Related to Python Polars

Comments

@nameexhaustion
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

q = pl.LazyFrame({"a": range(3)}).select(
    pl.first("a"),
    pl.col("a").alias("b"),
)

assert q.select(pl.len()).collect().item() == 3

# AssertionError: 1 == 3

Log output

No response

Issue description

Incorrect len()

Expected behavior

The non-scalar should be projected to give a len of 3

Installed versions

1.17.0

@nameexhaustion nameexhaustion added bug Something isn't working python Related to Python Polars needs triage Awaiting prioritization by a maintainer A-optimizer Area: plan optimization and removed needs triage Awaiting prioritization by a maintainer labels Dec 9, 2024
@nameexhaustion nameexhaustion self-assigned this Dec 9, 2024
@c-peters c-peters added the accepted Ready for implementation label Dec 14, 2024
@c-peters c-peters added this to Backlog Dec 14, 2024
@c-peters c-peters moved this to Done in Backlog Dec 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-optimizer Area: plan optimization accepted Ready for implementation bug Something isn't working python Related to Python Polars
Projects
Archived in project
2 participants