Huggingface.js documentation

类:InferenceClientRoutingError

Hugging Face's logo
Join the Hugging Face community

and get access to the augmented documentation experience

to get started

类:InferenceClientRoutingError

所有推理相关错误的基类。

层级

构造函数

constructor

• new InferenceClientRoutingError(message): InferenceClientRoutingError

参数

名称类型
messagestring

返回

InferenceClientRoutingError

覆盖

InferenceClientError.constructor

定义于

inference/src/errors.ts:21

属性

原因

• Optional 原因:unknown

继承自

InferenceClientError 的 cause

定义于

doc-internal/node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es2022.error.d.ts:26


消息

• message:string

继承自

InferenceClientError 的 message

定义于

doc-internal/node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1077


name

• name:string

继承自

InferenceClientError.name

定义于

doc-internal/node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1076


stack

• Optional 堆栈:string

继承自

InferenceClientError.stack

定义于

doc-internal/node_modules/.pnpm/[email protected]/node_modules/typescript/lib/lib.es5.d.ts:1078


prepareStackTrace

▪ Static Optional prepareStackTrace:(err: Error, stackTraces: CallSite[]) => any

用于格式化堆栈跟踪的可选覆盖

See

https://v8.dev/docs/stack-trace-api#customizing-stack-traces

类型声明

▸ (err, stackTraces): any

参数
名称类型
errError
stackTracesCallSite[]
返回

any

继承自

InferenceClientError.prepareStackTrace

定义于

inference/node_modules/.pnpm/@[email protected]/node_modules/@types/node/globals.d.ts:11


stackTraceLimit

▪ Static stackTraceLimit:number

继承自

InferenceClientError.stackTraceLimit

定义于

inference/node_modules/.pnpm/@[email protected]/node_modules/@types/node/globals.d.ts:13

方法

captureStackTrace

▸ captureStackTrace(targetObject, constructorOpt?): void

在目标对象上创建 .stack 属性

参数

名称类型
targetObjectobject
constructorOpt?Function

返回

void

继承自

InferenceClientError.captureStackTrace

定义于

inference/node_modules/.pnpm/@[email protected]/node_modules/@types/node/globals.d.ts:4

Update on GitHub