When a session's daemon answers a query with an explicit projectPath for another indexed project, it opens that project in-process and takes its writer lock (.codegraph/writer.pid, fallback mode). The project cache has no idle release, so the lock stays held for as long as that daemon runs. The project's own daemon then can't take the writer role, and codegraph index on it is blocked, until the first daemon exits. Reconnecting MCP servers doesn't help, because the daemon is detached.
Repro: two indexed projects A and B. Start an MCP session in A, call codegraph_explore with projectPath: <B>, then look at B/.codegraph/writer.pid: it names A's daemon and stays that way.
Fix: release a secondary project after an idle timeout (10 min by default, configurable), which frees its writer lock. Happy to open a PR with tests.
When a session's daemon answers a query with an explicit
projectPathfor another indexed project, it opens that project in-process and takes its writer lock (.codegraph/writer.pid, fallback mode). The project cache has no idle release, so the lock stays held for as long as that daemon runs. The project's own daemon then can't take the writer role, andcodegraph indexon it is blocked, until the first daemon exits. Reconnecting MCP servers doesn't help, because the daemon is detached.Repro: two indexed projects A and B. Start an MCP session in A, call
codegraph_explorewithprojectPath: <B>, then look atB/.codegraph/writer.pid: it names A's daemon and stays that way.Fix: release a secondary project after an idle timeout (10 min by default, configurable), which frees its writer lock. Happy to open a PR with tests.