Checks
Strands Version
Latest
Python Version
Latest
Operating System
Mac
Installation Method
pip
Steps to Reproduce
For both Graph and Swarm, the AfterNodeCallEvent is emitted even if a node is interrupted. This does not match the behavior for tool calls, which do not emit AfterToolCallEvents when interrupted.
To reproduce, you can run the integ tests under test_integ/interrupts/multiagent.
Expected Behavior
AfterNodeCallEvent should not emit if a node is interrupted. For single-agents, if a tool is interrupted, we do not emit the AfterToolCallEvent (src). There are a few motivations for this behavior:
- AfterToolCallEvent expects a tool result which we won't have until after the tool finishes executing.
- By its name, AfterToolCallEvent should happen after the tool is called, which is not the case if we are in the middle of processing an interrupt.
We should match this behavior for the node calls in multi-agents.
Actual Behavior
AfterNodeCallEvents emit even when a node is interrupted.
Additional Context
No response
Possible Solution
No response
Related Issues
No response
Checks
Strands Version
Latest
Python Version
Latest
Operating System
Mac
Installation Method
pip
Steps to Reproduce
For both Graph and Swarm, the AfterNodeCallEvent is emitted even if a node is interrupted. This does not match the behavior for tool calls, which do not emit AfterToolCallEvents when interrupted.
To reproduce, you can run the integ tests under test_integ/interrupts/multiagent.
Expected Behavior
AfterNodeCallEvent should not emit if a node is interrupted. For single-agents, if a tool is interrupted, we do not emit the AfterToolCallEvent (src). There are a few motivations for this behavior:
We should match this behavior for the node calls in multi-agents.
Actual Behavior
AfterNodeCallEvents emit even when a node is interrupted.
Additional Context
No response
Possible Solution
No response
Related Issues
No response