Skip to content

datafusion-cli regression: explain plan output looks bad (error rendering multi-lines) #14947

Closed
@alamb

Description

@alamb

Describe the bug

Explain plans look good in DataFusion 45:

DataFusion CLI v45.0.0
> create table foo(x int, y int) as values (1,2), (3,4);
0 row(s) fetched.
Elapsed 0.007 seconds.

> explain select * from foo where x = 4;
+---------------+---------------------------------------------------+
| plan_type     | plan                                              |
+---------------+---------------------------------------------------+
| logical_plan  | Filter: foo.x = Int32(4)                          |
|               |   TableScan: foo projection=[x, y]                |
| physical_plan | CoalesceBatchesExec: target_batch_size=8192       |
|               |   FilterExec: x@0 = 4                             |
|               |     MemoryExec: partitions=1, partition_sizes=[1] |
|               |                                                   |
+---------------+---------------------------------------------------+
2 row(s) fetched.
Elapsed 0.005 seconds.

However, they look really bad on main (aka pre-release DataFusion 46):

> create table foo(x int, y int) as values (1,2), (3,4);
0 row(s) fetched.
Elapsed 0.018 seconds.

> explain select * from foo where x = 4;
+---------------+--------------------------------------------------------------------------------------------------------------------------+
| plan_type     | plan                                                                                                                     |
+---------------+--------------------------------------------------------------------------------------------------------------------------+
| logical_plan  | Filter: foo.x = Int32(4)
  TableScan: foo projection=[x, y]                                                              |
| physical_plan | CoalesceBatchesExec: target_batch_size=8192
  FilterExec: x@0 = 4
    DataSourceExec: partitions=1, partition_sizes=[1]
 |
+---------------+--------------------------------------------------------------------------------------------------------------------------+
2 row(s) fetched.
Elapsed 0.013 seconds.

To Reproduce

create table foo(x int, y int) as values (1,2), (3,4);
explain select * from foo where x = 4;

Expected behavior

I expect the cells to be correctly rendered like in DataFUsion 45

Additional context

This appears to be another issue introduced by

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingregressionSomething that used to work no longer does

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions