Cubicle

CubicleBoxError

The CubicleBoxError class of @cubicle/sdk: its constructor, properties and methods.

A Box cannot reach the state being waited for: it failed, needs a new start after its host restarted, or another request changed its desired state.

code is box_failed, restart_required, hibernation_failed (the save failed; the Box keeps running and Cubicle retries at box.hibernationRetryAt) or box_superseded (another request changed its desired state, or it was deleted).

Extends

Constructors

Constructor

new CubicleBoxError(
   code, 
   message, 
   box
): CubicleBoxError;

Parameters

ParameterTypeDescription
code| "box_failed" | "box_superseded" | "restart_required" | "hibernation_failed"-
messagestring-
boxBoxInfoThe Box's last record. box.observed?.error says why a Box failed.

Returns

CubicleBoxError

Overrides

CubicleError.constructor

Properties

PropertyModifierTypeDescription
boxreadonlyBoxInfoThe Box's last record. box.observed?.error says why a Box failed.
cause?publicunknown-
codereadonlystringA stable machine-readable code, such as not_found or wait_timeout.
messagepublicstring-
namepublicstringAlways "CubicleBoxError".
stack?publicstring-

On this page