Skip to content

处理流式数据的错误报警 #735

@BoyangZhang619

Description

@BoyangZhang619

vConsole Version:反正当前npm包里最新的
在进行流式请求时,vonsole好像会对数据进行错误的处理导致输出(匿名函数报的错,我不知道啥类型)报错
部分个人输出:
installHook.js:1 ⚠️ 流式请求失败: Cannot read properties of undefined (reading 'length')
overrideMethod @ installHook.js:1
e.callOriginalConsole @ vconsole.min.js:10
e.addLog @ vconsole.min.js:10
(匿名) @ vconsole.min.js:10
(匿名) @ useAIChat.ts:296
await in (匿名)
(匿名) @ useAIChat.ts:369
handleSendChat @ AIChatView.vue:419
(匿名) @ AIChatView.vue:382
callWithErrorHandling @ vue.runtime.esm-bundler-CKUwx75R.js?v=d14f9530:1873
callWithAsyncErrorHandling @ vue.runtime.esm-bundler-CKUwx75R.js?v=d14f9530:1880
invoker @ vue.runtime.esm-bundler-CKUwx75R.js?v=d14f9530:7572
installHook.js:1 ⚠️ 移除流式占位符,尝试降级到非流式模式
overrideMethod @ installHook.js:1
e.callOriginalConsole @ vconsole.min.js:10
e.addLog @ vconsole.min.js:10
(匿名) @ vconsole.min.js:10
(匿名) @ useAIChat.ts:300
await in (匿名)
(匿名) @ useAIChat.ts:369
handleSendChat @ AIChatView.vue:419
(匿名) @ AIChatView.vue:382
callWithErrorHandling @ vue.runtime.esm-bundler-CKUwx75R.js?v=d14f9530:1873
callWithAsyncErrorHandling @ vue.runtime.esm-bundler-CKUwx75R.js?v=d14f9530:1880
invoker @ vue.runtime.esm-bundler-CKUwx75R.js?v=d14f9530:7572
installHook.js:1 [sendStreamMessage] 流式已收到数据但后续出错,不再降级
overrideMethod @ installHook.js:1
e.callOriginalConsole @ vconsole.min.js:10
e.addLog @ vconsole.min.js:10
(匿名) @ vconsole.min.js:10
(匿名) @ useAIChat.ts:314
await in (匿名)
(匿名) @ useAIChat.ts:369
handleSendChat @ AIChatView.vue:419
(匿名) @ AIChatView.vue:382
callWithErrorHandling @ vue.runtime.esm-bundler-CKUwx75R.js?v=d14f9530:1873
callWithAsyncErrorHandling @ vue.runtime.esm-bundler-CKUwx75R.js?v=d14f9530:1880
invoker @ vue.runtime.esm-bundler-CKUwx75R.js?v=d14f9530:7572
installHook.js:1 [handleSendMessage] 错误详情: TypeError: Cannot read properties of undefined (reading 'length')
at vconsole.min.js:10:221845
at async sendStreamMessage (useAIChat.ts:149:35)
at async handleSendMessage (useAIChat.ts:369:22)
at async handleSendChat (AIChatView.vue:419:18)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions