Skip to content

[Windows] git.exe console window flashes on daemon startup and branch switch #612

@XinAnzzZ

Description

@XinAnzzZ

Environment

  • OS: Windows 11
  • codegraph version: 0.9.6
  • Node: v24.12.0
  • Terminal: Windows Terminal

Steps to reproduce

  1. Initialize codegraph in any git repository (codegraph init -i)
  2. Run codegraph serve --mcp
  3. Observe: multiple cmd/console windows flash immediately on daemon startup
  4. Run git checkout <branch>
  5. Observe: cmd/console windows flash again on every branch switch
  6. Kill the daemon (codegraph stop)
  7. Run git checkout <branch> again
  8. Observe: no flashing — confirms daemon is the trigger

Expected behavior

No console windows should appear. Git subprocess calls should be hidden on Windows.

Actual behavior

Multiple cmd console windows flash briefly on:

  • Daemon startup (connect-time reconciliation)
  • Every git checkout / branch switch while daemon is running

--no-watch does not resolve the issue, which suggests the flashing
comes from the connect-time reconciliation path or the branch-switch handler,
not the file watcher path.

Analysis

The watcher path appears to already use windowsHide: true per the source
code. However, the reconciliation path triggered on daemon startup and on
branch switches appears to be spawning git.exe without windowsHide: true,
causing visible console flashes on Windows.

Screen recording

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions