QA mock provider emits toolcall_start with empty partial content; RPC-mode tool calls hang
Summary
The omo-senpi QA mock provider emits toolcall_start with partial.content: [] (packages/omo-senpi/scripts/qa/mock-provider/index.ts:207). Under senpi --mode rpc, the engine rejects that event with toolcall_start content at index 0 is not a tool call, and the turn hangs. Drivers that use -p (print mode) don't hit the check, so the existing e2e suites pass. Any RPC-mode QA driver that uses the mock provider cannot run a tool call.
Reproduction
- Start
senpi --mode rpcwith the omo-senpi plugin and the QA mock provider configured to answer with one tool call. - Send a prompt.
- Observed: stderr shows
toolcall_start content at index 0 is not a tool call; notool_execution_start, and the turn never ends.
Expected
The mock stream matches the real provider event contract. At toolcall_start, the partial message's content[contentIndex] is the tool-call block that is starting (at least { type: "toolCall", id, name, arguments: {} }). RPC-mode drivers then complete tool-call turns exactly as print-mode drivers do.
Evidence
Found while producing the live RPC proof for #9118. A one-line patched copy of the mock, which puts the tool-call block in partial.content, made the same RPC session complete: /computer status, a by-name computer call, then /computer status again. The patched copy is held locally in the #9113 evidence directory.
Acceptance criteria
- The mock emits a partial whose
content[contentIndex]is the tool-call block, for everytoolcall_*event. - A regression test drives one tool call through the mock in RPC mode and asserts
tool_execution_endplus turn completion. - The existing print-mode e2e suites still pass.
Source: code-yeongyu/oh-my-openagent