Skip to content

New-streaming engine with_columns with exclusively scalar output collapses length #20981

Closed
@orlp

Description

Example showing expected output from the eager engine and new-streaming output

>>> df = pl.DataFrame({"x": [1, 2, 3]})
>>> df.with_columns(pl.col.x.mean())
shape: (3, 1)
┌─────┐
│ x   │
│ --- │
│ f64 │
╞═════╡
│ 2.0 │
│ 2.0 │
│ 2.0 │
└─────┘
>>> df.lazy().with_columns(pl.col.x.mean()).collect(new_streaming=True)
shape: (1, 1)
┌─────┐
│ x   │
│ --- │
│ f64 │
╞═════╡
│ 2.0 │
└─────┘

Metadata

Assignees

Labels

P-highPriority: highacceptedReady for implementationbugSomething isn't workingnew-streamingFeatures for or dependent on the new streaming engine

Type

No type

Projects

  • Status

    Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions