Skip to content

EvalProviderError

PromptScript API


Defined in: eval/src/errors.ts:169

A provider call failed.

Extends

Constructors

Constructor

new EvalProviderError(message, code, details?): EvalProviderError

Defined in: eval/src/errors.ts:175

Parameters

message

string

code

EvalCode

details?
retryAfterMs?

number

status?

number

Returns

EvalProviderError

Overrides

EvalError.constructor

Properties

cause?

readonly optional cause?: Error

Defined in: core/src/errors/base.ts:56

Original error if wrapping another error

Inherited from

EvalError.cause


code

readonly code: string

Defined in: core/src/errors/base.ts:52

Error code

Inherited from

EvalError.code


location?

readonly optional location?: SourceLocation

Defined in: core/src/errors/base.ts:54

Source location where error occurred

Inherited from

EvalError.location


retryAfterMs?

readonly optional retryAfterMs?: number

Defined in: eval/src/errors.ts:173

Delay the provider asked for in retry-after, in milliseconds


status?

readonly optional status?: number

Defined in: eval/src/errors.ts:171

HTTP status of the failed call, when the provider answered

Methods

format()

format(): string

Defined in: core/src/errors/base.ts:79

Format error for display.

Returns

string

Inherited from

EvalError.format


toJSON()

toJSON(): Record<string, unknown>

Defined in: core/src/errors/base.ts:92

Convert to JSON-serializable object.

Returns

Record<string, unknown>

Inherited from

EvalError.toJSON