Automatic managed-settings refresh breaks IDE MCP reload and disables /allow-all
還沒有人認領這個 Issue。
- 主要語言
- Shell
- 星號
- 11.2k
- 分支
- 1.9k
- 平均合併
- 14 小時 16 分鐘
- 30 天內合併 PR
- 6
描述
Describe the bug
In a long-running Copilot CLI session connected to Visual Studio Code, an automatic managed-settings refresh can fail while reloading the dynamically contributed IDE MCP server:
Failed to enforce managed Computer Use policy: failed to reload Computer Use
plugin contributions for session '<redacted>':
MCP reload failed: mcpServers.ide.type: Invalid literal value
After this failure, the session enters a fail-closed permission state even though the resolved enterprise policy does not disable permission bypass. /allow-all and /yolo can no longer be enabled, and every tool call requires approval. Restarting Copilot CLI restores normal behavior.
This has occurred in multiple long-running sessions.
Affected version
GitHub Copilot CLI 1.0.84-6
The installed binary has since updated to 1.0.84-8; the failure has not yet been reproduced there.
Steps to reproduce the behavior
- Start Copilot CLI on Windows from a VS Code-integrated environment.
- Enable
/allow-allor/yolo. - Keep the session active until the automatic managed-settings refresh runs.
- Observe the IDE MCP graph reload fail with
mcpServers.ide.type: Invalid literal value. - Run
/allow-allor/yoloagain. - Observe that permission escalation is rejected and subsequent tool calls prompt individually.
- Restart Copilot CLI.
- Observe that permissions and MCP tools work normally again.
The failure may be timing-dependent. In the captured occurrence, it happened exactly one hour after the CLI process started.
Expected behavior
The periodic managed-settings refresh should accept the IDE-provided MCP transport configuration and preserve the existing MCP graph. If applying refreshed settings fails, a policy that explicitly allows bypass permissions should not be replaced by the restrictive "policy undetermined" state for the lifetime of the process.
Additional context
- OS: Microsoft Windows 10.0.26200, x64
- Shell: PowerShell 7.6.6
- IDE: Visual Studio Code
- No user-defined
mcpServersexisted in the CLIconfig.jsonorsettings.json. - The IDE bridge was registered through a Windows named pipe.
- Sanitized log sequence:
[managedSettings] effective policy resolved:
source=mdm, bypassDisabled=false, serverFetchFailed=false
[managedSettings] applied: no bypass restriction in force
mcp graph load: reload {"force":true}
[managedSettings] applied: bypass-permissions mode DISABLED
(fail-closed: policy could not be determined)
[managedSettings] self-fetch errored:
MCP reload failed: mcpServers.ide.type: Invalid literal value
Managed Computer Use plugin activation remains unreconciled {"attempts":3}
The public MCP configuration types are local/stdio and http/sse. This looks like a transient IDE bridge transport value (possibly the named-pipe transport) is being passed through generic MCP configuration validation during the forced reload.
貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
研究方向
首先,使用回報的 mcpServers.ide.type: Invalid literal value 序列,追蹤 Windows VS Code 整合 CLI 中 managed-settings 的自動重新整理,以及強制重新載入 MCP 圖。比較版本 1.0.84-6 與 1.0.84-8 之間的行為,並在啟用 /allow-all 或 /yolo 的情況下重現。完成標準是 IDE 的 MCP 設定能成功重新載入,且允許的繞過原則不會被 fail-closed 狀態取代。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- powershell, shell, vscode
- 領域
- cli, security, tooling
- Issue 類型
- 缺陷
- 難度
- 4/5
- 預估耗時
- 3-5 天
- 活躍度
- 活躍
- 描述清晰度
- 基本清楚
- 新手友好度
- 52/100