github / github/github-mcp-server

list_copilot_spaces / get_copilot_space tools don't return any results in Android Studio

オープン
#1,496 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る
bug
主要言語
Go
スター
33k
フォーク
5k
平均マージ
2日 1時間
マージ済み PR(30日)
52

説明

### Describe the bug

When using GitHub MCP with enabled `list_copilot_spaces` and `get_copilot_space` tools in Android studio, they do not return any output or errors despite everything is configured properly (my account has created Copilot Spaces, my PAT is correct and has necessary permissions, see more context below). Everything works perfectly for my account / PAT in VS Code (using OAuth) and in our internal web-based agent (using the same PAT).

### Affected version

I have Android Studio Otter | 2025.2.1 Patch 1
Build #AI-252.25557.131.2521.14432022, built on November 13, 2025

### Steps to reproduce the behavior

1. Create a new Copilot Space in https://github.com/copilot/spaces.
2. Optionally, add context from another repository (files).
3. Configure GitHub MCP in Android studio with the following configuration:
```
"github": {
"url": "https://api.githubcopilot.com/mcp/",
"requestInit": {
"headers": {
"Authorization": "Bearer myGitHubPat", // apparently, redacted for security
"X-MCP-Toolsets":"context,repos,issues,pull_requests,actions,copilot_spaces"
}
}
}
```
Note: the X-MCP-Toolsets header is needed to enable the list_copilot_spaces and get_copilot_space tools to be able to query my Copilot Spaces.

4. Restart Android Studio.
5. In Android Studio, go to Copilot chat -> select Agent mode -> Configure tools and verify that GitHub MCP is available and list_copilot_spaces and get_copilot_space tools are there.
6. Ask Copilot to call list_copilot_spaces and get_copilot_space tools.

### Expected vs actual behavior

Expected:
Both tools should return the Copilot Spaces data:
- `list_copilot_spaces` should return all my Copilot Spaces I have access to.
- `get_copilot_space` with the proper owner and Space name parameters should return the context of that space (general instructions, files added to its context, etc.).

Actual:
- Copilot sees both tools, calls them correctly but they return nothing, also no errors. So, Copilot keeps saying that my account do not have any Copilot Spaces created or do not have enough permissions.

To validate the latter, I performed 2 extra checks:
- replicated the same flow in VS Code, and got correct results: all my Copilot spaces from the `list_copilot_spaces` and could fetch a specific Copilot space via the `get_copilot_space` tool. However, the VS Code MCP configuration uses OAuth, so I didn't stop there and wanted to verify that my PAT also works.
- I used our in-house web-based agent and connected GitHub MCP to it using the same `https://api.githubcopilot.com/mcp/` URL and the same headers `{"Authorization": "Bearer myGitHubPat","X-MCP-Toolsets":"context,repos,issues,pull_requests,actions,copilot_spaces"}`. The web-based agent was able to connect to the GitHub MCO, discover it's tools including list_copilot_spaces` and `get_copilot_space`, call them and get correct data in return for both. So, I think I verified that my account, MCP configuration or my PAT are not a problem. It's something in Android Studio that causes this.

However, we cannot use VS Code or web-based agent because our department is all Android developers, and we must use Android Studio. So, VS Code is not a good workaround.

### Logs

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

Start by reproducing the list_copilot_spaces and get_copilot_space calls from Android Studio using the documented MCP URL, Authorization header, and X-MCP-Toolsets header. Compare the returned behavior with VS Code and the web-based agent, then trace the MCP request and response handling to identify why Android Studio receives neither data nor an error. Done means both tools return the expected Copilot Spaces data or report a clear error.

索引モデルが issue の本文から書いたものです。

評価

技術スタック
android, go
領域
api, devtools
issue の種類
バグ
難易度
4/5
見積もり時間
3〜5日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
35/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。