Skip to content

Commit

Permalink
Task.step(): fix handling of invalid recipient
Browse files Browse the repository at this point in the history
  • Loading branch information
pchalasani committed Dec 11, 2023
1 parent 0e34adb commit 8794345
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions langroid/agent/task.py
Original file line number Diff line number Diff line change
Expand Up @@ -475,7 +475,7 @@ def step(self, turns: int = -1) -> ChatDocument | None:
sender_name=Entity.AGENT,
),
)
self.pending_message = error_doc
self._process_responder_result(Entity.AGENT, parent, error_doc)
return error_doc

responders: List[Responder] = self.non_human_responders.copy()
Expand Down Expand Up @@ -545,7 +545,7 @@ async def step_async(self, turns: int = -1) -> ChatDocument | None:
sender_name=Entity.AGENT,
),
)
self.pending_message = error_doc
self._process_responder_result(Entity.AGENT, parent, error_doc)
return error_doc

responders: List[Responder] = self.non_human_responders_async.copy()
Expand Down

0 comments on commit 8794345

Please sign in to comment.