Skip to content

TablesPlot and FigureFactoryTable call render_error, which neither operator defines #7244

Closed

Description

@kz930

What happened?

Both operators report an unusable input by calling self.render_error(...), but neither generated class defines that method and UDFTableOperator does not provide one, so the branch meant to explain "no chart" raises AttributeError instead.

common/workflow-operator/src/main/scala/org/apache/texera/amber/operator/visualization/tablesChart/TablesPlotOpDesc.scala

|        if table.empty:
|           yield {'html-content': self.render_error("input table is empty.")}
|           return
|
|        ${manipulateTable()}
|
|        if table.empty:
|           yield {'html-content': self.render_error("value column contains only non-positive numbers or nulls.")}

The generated class contains one method:

class TableChartOperator(UDFTableOperator):

    def process_table(self, table: Table, port: int) -> Iterator[Optional[TableLike]]:
        if table.empty:
           yield {'html-content': self.render_error("input table is empty.")}

Executing it with an empty table raises the error below. FigureFactoryTableOpDesc has the same two call sites with the same omission. Both messages are therefore unreachable: an empty input, and an input whose configured columns are all null, fail the operator rather than rendering the page the code intends.

Every other visualization operator that renders an error page defines render_error inside its own generated class (BarChart, GaugeChart, DotPlot and so on), so the fix is the same three lines those carry.

How to reproduce?

  1. Build a workflow with any source into TablesPlot, and pick a column under Included Columns.
  2. Filter the input down to zero rows — a Filter whose predicate matches nothing will do — and run the workflow.

The operator fails with the error below instead of showing "input table is empty.". The same happens for FigureFactoryTable, and for either operator when the configured column holds only nulls.

Version/Branch

main

Commit Hash (Optional)

348fa88

Relevant log output

AttributeError: 'TableChartOperator' object has no attribute 'render_error'

Activity

  1. added theissue type on Aug 1, 2026
  2. kz930 commented on Aug 2, 2026

    @kz930
    ContributorAuthor

    /take

  3. added a commit that references this issue on Aug 7, 2026
    a96bf3e
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions