emitToolCall in packages/coding-agent/src/core/extensions/runner.ts:804-825 awaits each handler without a try/catch. Every other emit method (emitToolResult, emitMessageEnd, emitInput, and so on) wraps handlers and routes failures through emitError, so one broken extension cannot take down the rest.
For tool_call events a throw propagates out of emitToolCall. The caller in agent-session.ts catches it but re-throws, so the net effect is: remaining handlers never run, the tool call fails with the extension's error, and the failure bypasses the extension diagnostics the other events get. One buggy extension can break tool execution for the whole session.
Fix: mirror the try/catch + emitError pattern from the other emit methods. Only an explicit block result should short-circuit.
emitToolCallinpackages/coding-agent/src/core/extensions/runner.ts:804-825awaits each handler without a try/catch. Every other emit method (emitToolResult,emitMessageEnd,emitInput, and so on) wraps handlers and routes failures throughemitError, so one broken extension cannot take down the rest.For
tool_callevents a throw propagates out ofemitToolCall. The caller inagent-session.tscatches it but re-throws, so the net effect is: remaining handlers never run, the tool call fails with the extension's error, and the failure bypasses the extension diagnostics the other events get. One buggy extension can break tool execution for the whole session.Fix: mirror the try/catch +
emitErrorpattern from the other emit methods. Only an explicitblockresult should short-circuit.