Comma Agents
@comma-agents/core

Errors

Error classes for the Comma Agents framework.

Errors

All errors in Comma Agents extend CommaAgentsError, which itself extends the native Error class. Each error type includes a code property for programmatic handling.

Error Hierarchy

Error ClassCodeThrown When
CommaAgentsErrorCOMMA_AGENTS_ERRORBase class for all framework errors
AgentCallErrorAGENT_CALL_ERRORAgent call fails (LLM error, hook error)
FlowExecutionErrorFLOW_EXECUTION_ERRORFlow orchestration fails
HookExecutionErrorHOOK_EXECUTION_ERRORA hook throws during execution
ModelResolutionErrorMODEL_RESOLUTION_ERRORModel/provider cannot be resolved
StrategyValidationErrorSTRATEGY_VALIDATION_ERRORStrategy file fails schema validation
ToolExecutionErrorTOOL_EXECUTION_ERRORA tool's execute function throws

All error classes are exported from @comma-agents/core and can be used for instanceof checks or caught by their code property.

On this page