fix(acp): stop emitting user_message_chunk during session/prompt turn (#21851)

This commit is contained in:
RAIT-09 2026-04-15 01:25:00 +09:00 committed by GitHub
parent d312c677c5
commit a8f9f6b705
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -453,19 +453,6 @@ export namespace ACP {
return
}
}
if (part.type !== "text" && part.type !== "file") return
const msg = await this.sdk.session
.message(
{ sessionID: part.sessionID, messageID: part.messageID, directory: session.cwd },
{ throwOnError: true },
)
.then((x) => x.data)
.catch((err) => {
log.error("failed to fetch message for user chunk", { error: err })
return undefined
})
if (!msg || msg.info.role !== "user") return
await this.processMessage({ info: msg.info, parts: [part] })
return
}