Skip to content

Windows: Git discovery fails for valid repository at Unicode path #1240

Closed

Description

@NotaWhaIe

codebase-memory-mcp Windows Git discovery failure

Summary

codebase-memory-mcp 0.9.0 indexes the C# project and serves graph queries, but it does not recognize the indexed directory as a Git repository.

Environment

  • OS: Windows.
  • CBM: codebase-memory-mcp 0.9.0.
  • Git: git version 2.53.0.windows.1.
  • Indexed path: C:/Users/court/Scripts/W_Kr_Subsystem (Стойки).
  • The path includes non-ASCII Cyrillic characters.

Reproduction

git -C "C:/Users/court/Scripts/W_Kr_Subsystem (Стойки)" rev-parse --is-inside-work-tree
# true

git -C "C:/Users/court/Scripts/W_Kr_Subsystem (Стойки)" rev-parse --show-toplevel
# C:/Users/court/Scripts/W_Kr_Subsystem (Стойки)

git -C "C:/Users/court/Scripts/W_Kr_Subsystem (Стойки)" rev-parse --git-dir
# .git

The manually created CBM index reports status=ready, but its Git block contains is_git=false, root_exists=false, and null values for git_dir, branch, and HEAD.

Expected result

CBM should preserve the Git repository identity for a valid Windows repository at a Unicode path so that detect_changes and Git-backed index refresh work.

Notes

No source code, Revit logs, model data, commit IDs, or remote URLs are included in this report.

Activity

  1. added
    bugSomething isn't working
    editor/integrationEditor compatibility and CLI integration
    ux/behaviorDisplay bugs, docs, adoption UX
    priority/highNeeds near-term maintainer attention; high-impact bug, regression, safety issue, or release blocker.
    on Jul 24, 2026
  2. added this to the 0.9.1-rc milestone on Jul 24, 2026
  3. DeusData commented on Jul 24, 2026

    @DeusData
    Owner

    Confirmed against current main. The process entrypoint handles Windows arguments as UTF-16, but src/git/git_context.c still probes the repository with narrow stat(path) and constructs a narrow command for cbm_popen. That explains how indexing can succeed while root_exists and Git discovery fail for the same Cyrillic path. The RED needs a real Git repository under a non-ASCII Windows path and must assert root_exists, is_git, branch, and HEAD. High priority for 0.9.1-rc under #394.

  4. DeusData commented on Aug 14, 2026

    @DeusData
    Owner

    Thanks @NotaWhaIe — showing that git -C resolves the same Cyrillic path perfectly while cbm reports is_git=false and root_exists=false isolates this cleanly to our side, and you did it without including any of your source or model data, which was considerate.

    Confirmed against main: the entrypoint handles Windows arguments as UTF-16, but src/git/git_context.c still probes with narrow stat() and builds a narrow command line — which is exactly how indexing can succeed while the Git identity is lost. In practice that means detect_changes and Git-backed refresh do not work for anyone whose repository path is not ASCII.

    Not fixed yet. Tonight's v0.10.5 is being cut for the issues that block real use of the tool, and this is in that set. Sorry for the wait.

  5. DeusData commented on Sep 27, 2026

    @DeusData
    Owner

    Fixed on main in 6935df2 (PR #1816, thanks to @z2250389): Unicode repository paths now work on Windows. Thank you for the report and your patience!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingeditor/integrationEditor compatibility and CLI integrationpriority/highNeeds near-term maintainer attention; high-impact bug, regression, safety issue, or release blocker.ux/behaviorDisplay bugs, docs, adoption UXwindowsWindows-specific issues

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions