github / github/github-mcp-server

push_files takes ~70s per call (both success and fast-fail cases)

未關閉
#2,179 0 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視
主要語言
Go
星號
33k
分支
5k
平均合併
2 天 1 小時
30 天內合併 PR
52

描述

### Describe the bug

`push_files` calls are consistently slow (~1m12s–1m13s) in our MCP flow, even when one call fails with authorization error and the next call succeeds with the same payload.

This suggests significant latency before/around final Git operations, not only at final commit update step.

### Affected version

Using hosted/remote GitHub MCP server, version: `github-mcp-server/remote-57ddf9ca0de2f61fc022ca3cff21efc81a65fc99` (observed on 2026-03-08 via `initialize -> serverInfo.version`)

### Steps to reproduce the behavior

1. Call `github.push_files` with a payload of 7 files (Twig templates + one larger `classes/Email.php`) to:
- repo: https://github.com/Sogl/grav-plugin-login
- branch: https://github.com/Sogl/grav-plugin-login/tree/feature/multipart-emails
2. First call result:
- Error: `failed to create tree: POST https://api.github.com/repos/Sogl/grav-plugin-login/git/trees: 403 Resource not accessible by personal access token []`
- Client timing: `Worked for 1m 12s`
3. Fix PAT permissions and call `github.push_files` again with the same payload.
4. Second call result:
- Success, ref updated to commit: https://github.com/Sogl/grav-plugin-login/commit/8be0cd10415515109476025379545999f52b87b0
- Client timing: `Worked for 1m 13s`

### Expected vs actual behavior

Expected:
- Latency in seconds for this payload size, or at least clear diagnostics if server-side queueing/throttling is involved.

Actual:
- Both failed and successful calls take ~70+ seconds with almost identical duration.

### Logs

First call (failed, ~1m12s):
- `failed to create tree: POST https://api.github.com/repos/Sogl/grav-plugin-login/git/trees: 403 Resource not accessible by personal access token []`

Second call (success, ~1m13s):
- `{"ref":"refs/heads/feature/multipart-emails", ... "sha":"8be0cd10415515109476025379545999f52b87b0"}`

Request payload was the same large `push_files` body in both calls (7 files, full file contents).

貢獻指南

開啟貢獻指南

評估

這個 Issue 還沒有評估資料。

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。