Found while live-probing #638. A step_over on a session whose proxy is gone returns:
{"success": false, "error": "MCP error -32600: Cannot step over: no active proxy for session <id>"}
The MCP error -32600: prefix is protocol plumbing leaking into an application-level payload. It happens because the typed session errors (SessionNotFoundError, SessionTerminatedError, ProxyNotRunningError — src/errors/debug-errors.ts) extend McpError, whose constructor bakes MCP error <code>: into .message, and sessionErrorToResult (src/server/tool-result.ts:56) copies error.message into the envelope verbatim.
Every handler family that catches typed session errors emits the prefix, so an agent reading error gets a string that half-looks like a transport failure. The clean message is recoverable — the subclasses carry their own fields (sessionId, operation, state), or sessionErrorToResult could strip the known prefix pattern.
Scoped out of the #638 PR deliberately: it is cross-cutting (many handlers, many pinned test strings), and worth doing once, everywhere, rather than as a rider on a step-tools fix.
Found while live-probing #638. A
step_overon a session whose proxy is gone returns:{"success": false, "error": "MCP error -32600: Cannot step over: no active proxy for session <id>"}The
MCP error -32600:prefix is protocol plumbing leaking into an application-level payload. It happens because the typed session errors (SessionNotFoundError,SessionTerminatedError,ProxyNotRunningError—src/errors/debug-errors.ts) extendMcpError, whose constructor bakesMCP error <code>:into.message, andsessionErrorToResult(src/server/tool-result.ts:56) copieserror.messageinto the envelope verbatim.Every handler family that catches typed session errors emits the prefix, so an agent reading
errorgets a string that half-looks like a transport failure. The clean message is recoverable — the subclasses carry their own fields (sessionId,operation,state), orsessionErrorToResultcould strip the known prefix pattern.Scoped out of the #638 PR deliberately: it is cross-cutting (many handlers, many pinned test strings), and worth doing once, everywhere, rather than as a rider on a step-tools fix.