Workspace .mcp.json is never loaded in CLI 1.0.83 — 'mcp list' shows no Workspace group
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- Shell
- Star
- 11.2k
- Fork
- 1.9k
- Merge trung bình
- 14 giờ 16 phút
- Pull request đã merge (30 ngày)
- 6
Mô tả
Describe the bug
Copilot CLI 1.0.83 does not load workspace MCP config at all. A repo-root .mcp.json is ignored, and copilot mcp list never emits a Workspace group — only User servers:.
This is not a display-only problem: the servers are never started. The session log contains no spawn attempt for the workspace servers.
copilot mcp --help explicitly advertises the source:
Configuration is loaded from multiple sources:
User ~/.copilot/mcp-config.json
Workspace .mcp.json or .github/mcp.json
Plugin Installed plugins with MCP servers
Affected version
GitHub Copilot CLI 1.0.83.
macOS (Apple Silicon).
Steps to reproduce
In a pristine git repo, with no .vscode/ directory and no comments in the JSON:
mkdir repro && cd repro && git init -q .
cat > .mcp.json <<'JSON'
{
"mcpServers": {
"repro_probe": { "type": "local", "command": "node", "args": ["server.js"] }
}
}
JSON
copilot mcp list
copilot mcp get repro_probe
Actual behavior
$ copilot mcp list
User servers:
linear (http)
figma (http)
$ copilot mcp get repro_probe
Error: Server "repro_probe" not found.
copilot mcp list --json likewise contains only "source": "user" entries — no workspace entries at all.
Expected behavior
repro_probe appears under a Workspace group and is started for the session.
Ruled out
Each of these was tested individually, not assumed:
| Hypothesis | Result |
|---|---|
| Folder not trusted | Repo has an entry in ~/.copilot/permissions-config.json with write approvals |
| Version too old | 1.0.83; support shipped in v0.0.401 per #1291 |
| Enterprise/managed policy | Logs show managedSettings ... source=none, bypassDisabled=false |
"type": "stdio" vs "local" |
Both ignored |
mcpServers vs servers key |
Both ignored |
.github/mcp.json path |
Also ignored |
| Comments in JSON (#4323) | File is strict JSON, no comments; repro has no .vscode/mcp.json either |
| Not at repo root (#4765) | cwd is the repo root |
| Servers themselves broken | All start and authenticate fine when launched by hand, and work once copied into ~/.copilot/mcp-config.json |
Possibly related
- #3126 — same end symptom (
includeWorkspaceSourcesnever set), but reported via the SDK'senableConfigDiscoverypath. This report is the plain interactive CLI, so the two may share a root cause. - #4542 — there
mcp listdoes detect the workspace file and only the session connection fails; here it is never detected. - #4636 — startup reconciliation dropping servers in 1.0.81-11, but for
--additional-mcp-config.
Impact / workaround
Workspace .mcp.json is the only version-controlled way to share MCP servers with a team. The workaround is to duplicate every server into ~/.copilot/mcp-config.json using absolute paths, which is per-machine and not version-controlled, so each person repeats the setup and the lists drift.
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Bắt đầu bằng cách tái hiện sự cố với .mcp.json ở thư mục gốc của repo và so sánh việc CLI tương tác phát hiện workspace với đường dẫn cấu hình người dùng. Truy tìm lý do nguồn Workspace không xuất hiện trong copilot mcp list và xác nhận rằng cấu hình đã sửa vừa liệt kê server vừa khởi động server đó cho một phiên.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Lĩnh vực
- cli
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Sôi nổi
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức phù hợp với người mới
- 55/100