The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
fix(connectors): a failed account read no longer restarts a named account
Siddharth Balyan33457bc6823d
diff --git a/tools/connectors/managed.py b/tools/connectors/managed.pyindex 3ac11197938..b2ff9da0b5e 100644--- a/tools/connectors/managed.py+++ b/tools/connectors/managed.py@@ -226,15 +226,12 @@ def portal_accounts() -> list[dict[str, Any]]:def _alias_status(targets: list[Target]) -> Optional[dict[str, dict[str, Any]]]:"""``{slug: {"connected": bool}}`` for an aliased target, read from that account's own row;- ``None`` when no target is aliased. A failed read counts as not connected, so the repair mints."""+ ``None`` when no target is aliased. A failed read raises: guessing "not connected" would send+ the user through a new login for an account that may be healthy."""aliased = [t for t in targets if t.alias]if not aliased:return None- try:- rows = portal_accounts()- except ToolGatewayError as exc:- logger.debug("connector accounts read for reconnect failed: %s", exc)- rows = []+ rows = portal_accounts()return {t.name: {"connected": any(r.get("connector") == t.name and r.get("alias") == t.aliasand r.get("status") == "active" for r in rows)} for t in aliased}