Skip to content

.NET: [Bug]: Declarative EditTable operations replace itemsVariable with non-table values, preventing subsequent edits #7351

Description

@peibekwe

Description

After a successful Remove, or Clear, both EditTable and EditTableV2 can replace itemsVariable with a non-table value:

  • Remove: empty record or blank
  • Clear: blank

However, both executors require itemsVariable to be a TableValue before processing any operation:

Consequently, any subsequent table operation fails. Examples include:

•  Remove followed by Add 
•  Clear followed by Add 

The action therefore produces precisely the state that its own entry guard rejects.

What I expected to happen

After each operation,  itemsVariable  should remain bound to the mutated table:

•  Remove: table without the matching rows
•  Clear: an empty table retaining its schema

This would allow table operations to be composed and used in loops.

Steps to reproduce

  1. Seed a table variable.
  2. Apply a successful Remove.
  3. Apply Add against the same variable.
  4. Observe that Add fails because the variable now contains a record.

Code Sample

Error Messages / Stack Traces

Package Versions

Microsoft.Agents.AI.Workflows: 1.15.0 Microsoft.Agents.AI.Workflows.Declarative: 1.15.0

.NET Version

No response

Additional Context

This is related to, but intentionally separate from, #7323 , which address the corresponding behavior for Add.

Metadata

Metadata

Assignees

Labels

.NETUsage: [Issues, PRs], Target: .Net

Type

Projects

Status
No status

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions