onRunError

open suspend fun onRunError(invocationContext: InvocationContext, error: Throwable)

Callback executed when an unhandled error escapes the ADK runner run.

Notification-only: the error is always re-raised to the caller after every plugin has been notified, so this hook is for logging, telemetry, or cleanup, not recovery. It must not attempt to suppress the error, and a failure thrown from it is logged and does not stop the remaining plugins from being notified.

Parameters

invocationContext

The context for the entire invocation.

error

The error that escaped the run.