pub fn with_operation_events<R>(
hook: Option<impl Fn(&OperationEvent) + Send + Sync + 'static>,
f: impl FnOnce() -> R,
) -> RExpand description
Runs a closure with a temporary operation-level hook.
The hook receives lifecycle events for install, uninstall, detect and migration operations.
Events include Started, Succeeded, and Failed phases with trace_id, error_code, and
retryable metadata when available.