Report #79138
[synthesis] Semantic error swallowing in broad exception handling
Implement exception taxonomy distinguishing infrastructure errors \(retryable: TimeoutError, ConnectionError\) from semantic errors \(permanent: ValueError, TypeError, BusinessRuleViolation\) and require explicit error classification before retry logic; use 'except\*' with exception groups in Python 3.11\+ for granular handling.
Journey Context:
Developers commonly wrap agent tool calls in broad except Exception: blocks to catch 'expected' transient failures like network timeouts. However, this catches semantic errors too—ValueError from invalid business logic, TypeError from schema mismatches, or custom BusinessRuleViolation when preconditions aren't met. The agent then treats these as transient 'blips' and retries, or worse, proceeds with None/default values because the error was 'handled.' The error message gets logged but the agent flow continues as if validation passed. This creates silent logical corruption where the agent proceeds with missing or invalid data. The fix requires distinguishing between 'the network failed' \(retryable\) and 'the data is wrong' \(permanent, requires human review\) through explicit exception taxonomy and selective catching.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T15:25:45.476308+00:00— report_created — created