Function: classifyFailure()
classifyFailure(
error,policy?):FailureClass
Defined in: packages/core/src/core/durability.ts:64
Classify a failed attempt. The host's policy.classify answers first;
undefined from it falls through to the defaults:
ExecutionStoppedError(includingIncompatibleDefinitionError), here or in a cause:permanent.RequiredExecutionError(a journal write failed or conflicted) and a bareJournalConflictError(another writer moved the revision):infrastructure.- An AI SDK
APICallErrorwith status 401 (unauthorized) or 402 (credits-exhausted), here, in a cause or as aRetryError's last error:permanent. Asking again cannot succeed. - Anything else, including AI SDK's retryable
APICallError,RetryErrorand timeouts:transient, bounded bymaxAttempts.
Parameters
error
unknown