Skip to content

A programming framework for agentic AI

fix(magentic-one): Remove redundant exception raising in update_ledger (#4759)

Roy Belio3dd4be949e95
diff --git a/python/packages/autogen-magentic-one/src/autogen_magentic_one/agents/orchestrator.py b/python/packages/autogen-magentic-one/src/autogen_magentic_one/agents/orchestrator.py
index 9cd28a15e..2bcd3020f 100644
--- a/python/packages/autogen-magentic-one/src/autogen_magentic_one/agents/orchestrator.py
+++ b/python/packages/autogen-magentic-one/src/autogen_magentic_one/agents/orchestrator.py
@@ -249,14 +249,13 @@ class LedgerOrchestrator(BaseOrchestrator):
if key_error:
continue
return ledger_dict
- except json.JSONDecodeError as e:
+ except json.JSONDecodeError:
self.logger.info(
OrchestrationEvent(
f"{self.metadata['type']} (error)",
f"Failed to parse ledger information: {ledger_str}",
)
)
- raise e
raise ValueError("Failed to parse ledger information after multiple retries.")