mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-05-06 22:32:39 +02:00
fix(multi-agent): degrade to builtins-only when MCP or subagent registry build fails
This commit is contained in:
parent
3cb2c3056e
commit
a421e7d792
2 changed files with 16 additions and 3 deletions
|
|
@ -126,8 +126,12 @@ def build_main_agent_deepagent_middleware(
|
|||
[s["name"] for s in subagents_registry],
|
||||
)
|
||||
except Exception:
|
||||
logging.exception("Subagents registry build failed")
|
||||
raise
|
||||
# Degrade to general-purpose-only rather than aborting the turn:
|
||||
# one bad subagent dep should not deny the user a response.
|
||||
logging.exception(
|
||||
"Subagents registry build failed; falling back to general-purpose only"
|
||||
)
|
||||
subagents_registry = []
|
||||
|
||||
subagents: list[SubAgent] = [general_purpose_subagent, *subagents_registry]
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue