auto-sync: 2026-05-26 13:48:56

This commit is contained in:
cfdaily
2026-05-26 13:48:56 +08:00
parent ef6917b318
commit b8ef9ef4b7
+4 -5
View File
@@ -624,18 +624,17 @@ curl -X POST http://{api_host}:{api_port}/api/projects/{project_id}/tasks/{task_
elif outcome == "fallback_timeout" and not cls["should_retry"]:
# A5/A6: fallback 不应出现,标 failed + escalate + context 日志
logger.error("UNEXPECTED FALLBACK: agent=%s session=%s task=%s "
"transport=%s fallbackReason=%s counter_active=%s "
"fallback_used=%s fallback_reason=%s counter_active=%s "
"This indicates counter check failed to prevent concurrent spawn.",
agent_id, session_id, task_id,
meta.get("transport"), meta.get("fallbackReason"),
json_result.get("fallback_used"), json_result.get("fallback_reason"),
self.counter.active_agents if self.counter else "N/A")
await self._do_on_complete_async(on_complete, agent_id, outcome)
if db_path and task_id:
self._mark_task(db_path, task_id, "failed", {
"reason": "unexpected_fallback",
"transport": meta.get("transport"),
"fallback_reason": meta.get("fallbackReason"),
"duration_ms": meta.get("durationMs"),
"status": json_result.get("status"),
"fallback_reason": json_result.get("fallback_reason"),
})
else:
# 其他:A1(completed), A4(agent_failed), A7(auth_failed),