auto-sync: 2026-05-26 10:48:44
This commit is contained in:
@@ -987,7 +987,17 @@ curl -X POST http://{api_host}:{api_port}/api/projects/{project_id}/tasks/{task_
|
||||
return {"outcome": "fallback_timeout", "should_retry": False}
|
||||
|
||||
# A2/A3: Gateway timeout(任务没完成)— 唯一续杯场景
|
||||
# P2 兜底:如果 transport 仍为空(解析失败),检查 stderr 判断是否是 lock/compact 等
|
||||
if exit_code == 0 and not is_terminal:
|
||||
# P2: transport=null 时检查 stderr 辅助判断
|
||||
if not transport:
|
||||
stderr_lower = stderr_text.lower()
|
||||
if any(kw in stderr_lower for kw in ["lock", "busy", "concurrent", "lane task error"]):
|
||||
return {"outcome": "lock_conflict", "should_retry": False}
|
||||
if any(kw in stderr_lower for kw in ["compaction-diag", "context-overflow"]):
|
||||
return {"outcome": "compact_failed", "should_retry": False}
|
||||
if any(kw in stderr_lower for kw in ["rate_limit", "500", "503"]):
|
||||
return {"outcome": "api_error", "should_retry": False}
|
||||
return {"outcome": "gateway_timeout", "should_retry": True,
|
||||
"retry_field": "retry_count"}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user