# ScalarSketchParseError

Defined in: [packages/scalar-sketch/src/errors.ts:60](https://github.com/jkomyno/knotkit/blob/ef04dc6fd5182dca281abddf3e1dcb13118c15a4/packages/scalar-sketch/src/errors.ts#L60)

Thrown when a scalar-sketch persistence envelope or family state is invalid.

## Extends

* [`ParseError`](/reference/knotkit/errors/classes/parseerror/)<[`ScalarSketchParseErrorCode`](/reference/knotkit/scalar-sketch/type-aliases/scalarsketchparseerrorcode/)>

## Constructors

### Constructor

> **new ScalarSketchParseError**(`code`, `message`): `ScalarSketchParseError`

Defined in: [packages/errors/src/index.ts:57](https://github.com/jkomyno/knotkit/blob/ef04dc6fd5182dca281abddf3e1dcb13118c15a4/packages/errors/src/index.ts#L57)

#### Parameters

##### code

`"INVALID_CODEC_RESULT"` | `"INVALID_MAGIC"` | `"UNSUPPORTED_ENVELOPE_VERSION"` | `"UNSUPPORTED_PAYLOAD_VERSION"` | `"INVALID_SECTION_GEOMETRY"` | `"NONZERO_PADDING"` | `"MISALIGNED_SECTION"` | `"TRUNCATED_PAYLOAD"` | `"DECODE_BUDGET_EXCEEDED"` | `"UNSTABLE_BUFFER"` | `"WRONG_FORMAT"` | `"INTEGRITY_MISMATCH"` | `"UNKNOWN_KIND"` | `"INVALID_PACKAGE_HEADER"` | `"INVALID_SHAPE"` | `"INVALID_STATE"` | `"STATE_TOO_LARGE"` | `"INVALID_ENVELOPE"` | `"UNKNOWN_SCALAR_KIND"` | `"UNSUPPORTED_WIRE_VERSION"` | `"UNSUPPORTED_PRODUCER_VERSION"` | `"UNSUPPORTED_SCHEDULE"`

##### message

`string`

#### Returns

`ScalarSketchParseError`

#### Inherited from

[`ParseError`](/reference/knotkit/errors/classes/parseerror/).[`constructor`](/reference/knotkit/errors/classes/parseerror/#constructor)

## Properties

### \_tag

> `readonly` **\_tag**: `"ParseError"`

Defined in: [packages/errors/src/index.ts:55](https://github.com/jkomyno/knotkit/blob/ef04dc6fd5182dca281abddf3e1dcb13118c15a4/packages/errors/src/index.ts#L55)

#### Inherited from

[`ParseError`](/reference/knotkit/errors/classes/parseerror/).[`_tag`](/reference/knotkit/errors/classes/parseerror/#_tag)

***

### code

> `readonly` **code**: `"INVALID_CODEC_RESULT"` | `"INVALID_MAGIC"` | `"UNSUPPORTED_ENVELOPE_VERSION"` | `"UNSUPPORTED_PAYLOAD_VERSION"` | `"INVALID_SECTION_GEOMETRY"` | `"NONZERO_PADDING"` | `"MISALIGNED_SECTION"` | `"TRUNCATED_PAYLOAD"` | `"DECODE_BUDGET_EXCEEDED"` | `"UNSTABLE_BUFFER"` | `"WRONG_FORMAT"` | `"INTEGRITY_MISMATCH"` | `"UNKNOWN_KIND"` | `"INVALID_PACKAGE_HEADER"` | `"INVALID_SHAPE"` | `"INVALID_STATE"` | `"STATE_TOO_LARGE"` | `"INVALID_ENVELOPE"` | `"UNKNOWN_SCALAR_KIND"` | `"UNSUPPORTED_WIRE_VERSION"` | `"UNSUPPORTED_PRODUCER_VERSION"` | `"UNSUPPORTED_SCHEDULE"`

Defined in: [packages/errors/src/index.ts:58](https://github.com/jkomyno/knotkit/blob/ef04dc6fd5182dca281abddf3e1dcb13118c15a4/packages/errors/src/index.ts#L58)

#### Inherited from

[`ParseError`](/reference/knotkit/errors/classes/parseerror/).[`code`](/reference/knotkit/errors/classes/parseerror/#code-1)

***

### moduleName

> `readonly` **moduleName**: `"knotkit/scalar-sketch"`

Defined in: [packages/scalar-sketch/src/errors.ts:61](https://github.com/jkomyno/knotkit/blob/ef04dc6fd5182dca281abddf3e1dcb13118c15a4/packages/scalar-sketch/src/errors.ts#L61)

#### Overrides

[`ParseError`](/reference/knotkit/errors/classes/parseerror/).[`moduleName`](/reference/knotkit/errors/classes/parseerror/#modulename)
