Skip to content

deserializeEngineError

function deserializeEngineError(dto): EngineError;

Defined in: packages/engine/src/errors/WorkerError.ts:88

Rebuild an EngineError from its transported form.

The category string round-trips straight back into the ErrorCategory enum (its members ARE their own string values), so a main-side catch reads the same category the worker raised. A malformed category (a message that was not produced by serializeEngineError) falls back to INTERNAL rather than constructing an error with an invalid category.

ParameterType
dtoSerializedEngineError

EngineError