fix(opencode): include acp pending tool input (#31321)

This commit is contained in:
Shoubhit Dash
2026-06-08 12:20:59 +05:30
committed by GitHub
parent 79ea379df2
commit 685a894a6f
3 changed files with 41 additions and 4 deletions
+1
View File
@@ -330,6 +330,7 @@ export class Subscription {
...pendingToolCall({
toolCallId: part.callID,
toolName: part.tool,
state: part.state,
}),
},
})
+8 -4
View File
@@ -118,14 +118,18 @@ export function completedToolContent(toolName: string, state: CompletedToolState
return content
}
export function pendingToolCall(input: { readonly toolCallId: string; readonly toolName: string }): ToolCall {
export function pendingToolCall(input: {
readonly toolCallId: string
readonly toolName: string
readonly state: { readonly input: ToolInput; readonly title?: string }
}): ToolCall {
return {
toolCallId: input.toolCallId,
title: input.toolName,
title: input.state.title || input.toolName,
kind: toToolKind(input.toolName),
status: "pending",
locations: [],
rawInput: {},
locations: toLocations(input.toolName, input.state.input),
rawInput: input.state.input,
}
}