Skip to content

API reference / @jsprismarine/errors / script-host

script-host ​

Classes ​

Variables ​

ScriptHostErrors ​

const ScriptHostErrors: Readonly<{ ApiError: typeof ApiError; ArgumentConversionFailed: typeof ArgumentConversionFailed; ArgumentNotOfType: typeof ArgumentNotOfType; ArgumentVariantConversionFailed: typeof ArgumentVariantConversionFailed; ConnectFailed: typeof ConnectFailed; ConnectionWorkerOnMainThread: typeof ConnectionWorkerOnMainThread; DebuggerAlreadyAttached: typeof DebuggerAlreadyAttached; DebuggerClosedConnection: typeof DebuggerClosedConnection; DebuggerDetached: typeof DebuggerDetached; DebuggerPasscodeMismatch: typeof DebuggerPasscodeMismatch; DebuggerPluginNotFound: typeof DebuggerPluginNotFound; DebuggerProtocolVersionMismatch: typeof DebuggerProtocolVersionMismatch; DebuggerThreadExited: typeof DebuggerThreadExited; DebuggerThreadRequestFailed: typeof DebuggerThreadRequestFailed; DebuggerThreadStopped: typeof DebuggerThreadStopped; DebuggerThreadThrew: typeof DebuggerThreadThrew; DebugSessionAlreadyAttached: typeof DebugSessionAlreadyAttached; DebugSessionDetached: typeof DebugSessionDetached; DeferredPromiseIncomplete: typeof DeferredPromiseIncomplete; DeferredPromiseNotAList: typeof DeferredPromiseNotAList; DependencyHasNoShape: typeof DependencyHasNoShape; DisplayOptionsNotAnObject: typeof DisplayOptionsNotAnObject; EngineDestroyed: typeof EngineDestroyed; EngineDestroyedDuringHostCall: typeof EngineDestroyedDuringHostCall; EngineGlobalMissing: typeof EngineGlobalMissing; EngineNotCreated: typeof EngineNotCreated; EngineRejectedValue: typeof EngineRejectedValue; EvaluateWhileRunning: typeof EvaluateWhileRunning; EventNoLongerValid: typeof EventNoLongerValid; ExpectedStringValue: typeof ExpectedStringValue; ExportNotOfModuleClass: typeof ExportNotOfModuleClass; FormKitFunctionMissing: typeof FormKitFunctionMissing; FrameBodyNotJson: typeof FrameBodyNotJson; FrameNotRead: typeof FrameNotRead; FrameTooLong: typeof FrameTooLong; ImplementedTwice: typeof ImplementedTwice; InfinityNotSupported: typeof InfinityNotSupported; InterfacePropertyConversionFailed: typeof InterfacePropertyConversionFailed; InterfacePropertyMissing: typeof InterfacePropertyMissing; InterfacePropertyNotFinite: typeof InterfacePropertyNotFinite; InvalidDebuggerMessage: typeof InvalidDebuggerMessage; InvalidFrameHeader: typeof InvalidFrameHeader; InvalidPlayerHandle: typeof InvalidPlayerHandle; JspMemberUnavailable: typeof JspMemberUnavailable; JspModuleArgument: typeof JspModuleArgument; LibraryInterfaceMismatch: typeof LibraryInterfaceMismatch; ListenerClosed: typeof ListenerClosed; ListenerHasNoAddress: typeof ListenerHasNoAddress; ListenerNeedsPasscode: typeof ListenerNeedsPasscode; ListenFailed: typeof ListenFailed; LiteralEvaluatedToPrimitive: typeof LiteralEvaluatedToPrimitive; ManifestHeaderIncomplete: typeof ManifestHeaderIncomplete; MemberNotPrivileged: typeof MemberNotPrivileged; ModuleNotFound: typeof ModuleNotFound; ModuleVersionConflict: typeof ModuleVersionConflict; ModuleVersionMissing: typeof ModuleVersionMissing; NoScriptStopped: typeof NoScriptStopped; NotAFormBuilderMember: typeof NotAFormBuilderMember; NotAFunction: typeof NotAFunction; NotAnObject: typeof NotAnObject; NotImplemented: typeof NotImplemented; ObjectCarriesNoState: typeof ObjectCarriesNoState; PackFileNotAnObject: typeof PackFileNotAnObject; PlaceholderName: typeof PlaceholderName; PlaceholderNamespaceTaken: typeof PlaceholderNamespaceTaken; PlaceholderNoKeys: typeof PlaceholderNoKeys; ReceivedFrameTooLong: typeof ReceivedFrameTooLong; ScriptModuleWithoutUuid: typeof ScriptModuleWithoutUuid; ScriptOutOfMemory: typeof ScriptOutOfMemory; ScriptTerminated: typeof ScriptTerminated; ScriptThrew: typeof ScriptThrew; SegmentVersionMissing: typeof SegmentVersionMissing; TaskDelayNotFinite: typeof TaskDelayNotFinite; TemplateCondition: typeof TemplateCondition; TemplateInvalid: typeof TemplateInvalid; TestNoLongerBound: typeof TestNoLongerBound; TextConversionFailed: typeof TextConversionFailed; UnhandledDebuggerCommand: typeof UnhandledDebuggerCommand; UnknownApiMember: typeof UnknownApiMember; UnknownEngineRequest: typeof UnknownEngineRequest; UnknownHostFunction: typeof UnknownHostFunction; UnknownPauseReason: typeof UnknownPauseReason; UnknownValueTag: typeof UnknownValueTag; UnknownVariablesReference: typeof UnknownVariablesReference; UnrecognizedModule: typeof UnrecognizedModule; ValueCannotCrossIntoScript: typeof ValueCannotCrossIntoScript; ValueRunsPastBytes: typeof ValueRunsPastBytes; VariantConversionFailed: typeof VariantConversionFailed; VersionsNotComparable: typeof VersionsNotComparable; }>

Defined in: packages/errors/src/script-host.ts:3076

The errors @jsprismarine/script-host throws in Node.js. Errors a script sees from code that runs inside the engine are the engine's own TypeError, RangeError and ReferenceError, as on Bedrock Dedicated Server, and are not listed here.