Skip to content

Commit 528e158

Browse files
committed
fix: add early return in matmaster_check_job_status to handle error occurrence and prevent processing
1 parent 82ce500 commit 528e158

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

agents/matmaster_agent/callback.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,8 @@ async def matmaster_check_job_status(
107107
- 上一条为True,当前为False:说明流式消息输出即将结束
108108
- 上一条为False,当前为True:说明新的一条消息开始了
109109
"""
110+
if callback_context.state['error_occurred']:
111+
return
110112

111113
if (jobs_dict := callback_context.state['long_running_jobs']) and has_job_running(
112114
jobs_dict

0 commit comments

Comments
 (0)