Subagents created with enableMCP=false had toolSession.mcpManager unset, causing depth-2+ sub-subagents to re-discover and spawn duplicate MCP server processes. - Add mcpManager option to CreateAgentSessionOptions - Set toolSession.mcpManager unconditionally after MCP block - Pass options.mcpManager from executor to createAgentSession - Guard callback registration: only wire onToolsChanged/onPromptsChanged/ onResourcesChanged when the session owns the manager (created via discovery), not when reusing a parent's — prevents child sessions from clobbering the parent's live MCP refresh handlers Latent since91da560cc(in-process subagent migration), observable sincef82a5d121added task.maxRecursionDepth allowing depth-2 agents.
@oh-my-pi/pi-coding-agent
Core implementation package for the omp coding agent in the oh-my-pi monorepo.
For installation, setup, provider configuration, model roles, slash commands, and full CLI reference, see:
Package-specific references: