"Build" button creates hidden shadow agent that doesn't show in UI, locks tool

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

Bug: “Build” on a saved plan spawns a parallel agent; opening it evicts the active session tab

Environment

  • OS: Linux (kernel 6.17.0-22-generic)
  • Cursor version: Version:
    3.1.17
    VSCode Version: 1.105.1
    Commit: fce1e9ab7844f9ea35793da01e634aa7e50bce90
    Date: 2026-04-19T19:33:58.189Z
    Layout: editor
    Build Type: Stable
    Release Track: Default
    Electron: 39.8.1
    Chromium: 142.0.7444.265
    Node.js: 22.22.1
    V8: 14.2.231.22-electron.0
    OS: Linux x64 6.17.0-22-generic
  • Workspace: single-folder local repo
  • Mode: started in plan mode, completed plan revision in chat

Summary

Two distinct UX failures combined into a near-silent dual-agent state with potential for write-write conflicts on the working tree.

Actual behavior

  • Clicking “Build” spawns a second agent process, separate from the chat session, with the answered plan as its input.
  • The original chat session sees an internal “Questions skipped” signal (no answer routes back to it) and sits orphaned at its AskQuestion step.
  • Both agents now have read/write access to the same working tree with no coordination, no mutex, and no UI indication that two agents are live.
  • The build-spawned agent is not visible in the main agent panel; it can only be located by clicking through the plan UI itself.

Additional UI bug observed during recovery

  • After the build-spawned agent stalled (blocked on its own input), I located it by clicking through the plan UI.
  • The act of opening the build-spawned agent’s tab caused my original chat session’s tab to disappear from the main editor window.
  • The original session was still alive backend-side, but UX-wise it appeared lost — there was no breadcrumb or indication of where it had gone.

Impact

  • Two agents writing to the same files produced a partial implementation: contract changes from agent B, test changes from agent A, no shared awareness, broken test suite.
  • Recovery required killing the rogue agent and manually reconciling the tree.
  • High potential for silent data-state divergence on any non-trivial multi-file change.

Suggested fixes

  • Treat plan-mode chat session and plan-UI build as a single driver. While a plan-mode chat is active in the workspace, either:
    • disable the plan UI’s Build button, or
    • have Build deliver a “begin executing” signal to the already-active session instead of spawning a new agent.
  • Route plan-UI answers back to the originating chat session rather than (or in addition to) the build pipeline.
  • Ensure all live agents in a workspace are visible in a single agent panel, regardless of how they were spawned. No agent should be reachable only by clicking through a plan.
  • Don’t evict tabs from the main editor when opening an agent tab; if a layout change is needed, surface a notification or breadcrumb so the displaced session is discoverable.

Severity

High. Codebase-corruption-class. The dual-write race is silent and only discoverable by inspecting git diff and noticing edits the user did not author.

Steps to Reproduce

Steps to reproduce

  1. Open an existing plan (~/.cursor/plans/<name>.plan.md) and start a chat session in plan mode against it.
  2. Continue iterating on the plan in chat. The agent calls AskQuestion (an interactive multiple-choice prompt) somewhere in plan mode.
  3. Answer the question via the prompt rendered in the plan UI (not in chat). Then click the “Build” button on the plan.

Expected Behavior

Expected behavior

  • Either the “Build” button is disabled while a plan-mode chat session is already active in the same workspace, OR
  • “Build” instructs the already-active agent in the chat session to begin executing the plan (single agent, single editor over the workspace).

Operating System

Linux

Version Information

Version: 3.1.17
VSCode Version: 1.105.1
Commit: fce1e9ab7844f9ea35793da01e634aa7e50bce90
Date: 2026-04-19T19:33:58.189Z
Layout: editor
Build Type: Stable
Release Track: Default
Electron: 39.8.1
Chromium: 142.0.7444.265
Node.js: 22.22.1
V8: 14.2.231.22-electron.0
OS: Linux x64 6.17.0-22-generic

For AI issues: which model did you use?

Was using Opus 4.7 in Chat, but the “build” used “Auto”

Does this stop you from using Cursor

No - Cursor works, but with this issue

Hey, thanks for the detailed report. Environment, repro steps, expected vs actual, suggested fixes, it’s all there, and it really makes this easier to work on.

The scenario is reproducible and matches what we’re seeing on our side. With an active plan-mode chat session that’s still pending on AskQuestion, Build doesn’t block or route the result back to the existing agent. Instead it spawns a parallel one. There’s also no coordination between them on the working tree, which is exactly what you noticed.

I’ve filed this internally as a bug. I can’t share an ETA for the fix yet. If I get an update, I’ll reply in the thread.

For now, the workaround is: don’t hit Build while the chat session is stuck on AskQuestion. Close the question in chat or cancel the session, then run Build from the plan. And like you said, git diff is the only reliable way to catch divergence after the fact, so committing more often when working in plan mode is a good idea.