Add read-only regression coverage for dynamic toolsets and deprecated aliases
还没有人认领这个 Issue。
评估
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 新手友好度
- 55/100
- Issue 类型
- 功能
- 描述清晰度
- 描述清楚
- 活跃度
- 停滞
- 技术栈
- github, go
调研方向
从 pkg/github/dynamic_tools.go 中的动态工具注册、pkg/github/deprecated_tool_aliases.go 中的弃用别名映射,以及 internal/ghmcp/server.go 中的清单组装开始。以 pkg/http/handler_test.go 中的请求级过滤测试作为入口。完成的标准是:针对性测试表明,动态启用的变更工具和已弃用的变更别名在只读模式下仍不可用。
由索引模型根据 Issue 内容生成。
描述
Read-only guarantees currently depend on implicit inventory behavior that is not regression-tested across dynamic toolset enablement and deprecated alias resolution.
Current behavior is insufficient because the server's read-only contract spans multiple capability surfaces (DynamicTools, inventory filtering, and deprecated alias lookup), but there is no focused test that proves mutating canonical tools and deprecated aliases stay unavailable when read-only mode is active.
Why now: --read-only is a core governance boundary for this server, so the contract should be locked in with explicit regression coverage before toolset and alias work drifts further.
Claim-to-codepath map:
- Dynamic toolset registration in
pkg/github/dynamic_tools.go - Deprecated alias mapping in
pkg/github/deprecated_tool_aliases.go - Server inventory assembly in
internal/ghmcp/server.go - Request-level filtering tests in
pkg/http/handler_test.go
Requested behavior:
- Read-only mode should continue to exclude mutating tools when a toolset is enabled dynamically.
- Deprecated aliases for mutating tools should not re-expose write capability under read-only filtering.
- The invariant should be covered by targeted tests.
Evidence Packet
- Commit under test:
1da41fa6947f - Runtime environment:
- OS: Darwin 25.3.0 arm64
- Go: go1.25.7
- golangci-lint: 2.8.0
- Minimal repro:
- Build inventory/server state with read-only mode enabled.
- Exercise dynamic toolset enablement and deprecated alias lookup.
- Verify whether any mutating capability becomes available.
- Expected behavior: no mutating canonical tool or deprecated alias becomes callable in read-only mode.
- Actual behavior: the code path is not covered by a focused regression test today.
Acceptance Criteria
- Add targeted tests proving read-only behavior holds for dynamic toolsets and deprecated aliases.
- Keep the change scoped to regression coverage unless a concrete behavior bug is found.
- 主要语言
- Go
- 星标
- 33.1k
- 派生
- 5k
- 平均合并
- 2 天 1 小时
- 30 天内合并 PR
- 25
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
github/github-mcp-server 的其他 Issue
-
bug
难度 2/5 1-3 小时 新手友好度 84/100
github/github-mcp-server#3235 ·
-
enhancement
难度 1/5 1 小时以内 新手友好度 88/100
github/github-mcp-server#3042 · 2 条评论 ·
-
bug
难度 2/5 1-3 小时 新手友好度 72/100
github/github-mcp-server#3032 · 1 个 reaction ·
-
难度 2/5 1-3 小时 新手友好度 74/100
github/github-mcp-server#2803 · 1 条评论 ·
-
难度 2/5 1-3 小时 新手友好度 76/100
github/github-mcp-server#2740 ·
查看 github/github-mcp-server 的全部 Issue
相似的 Issue
-
textual definition
难度 1/5 1 小时以内 新手友好度 90/100
geneontology/go-ontology#32653 ·
-
难度 1/5 1 小时以内 新手友好度 75/100
-
needs design
难度 2/5 1-3 小时 新手友好度 75/100
-
Priority/High ready-for-agent Severity/Major Type/Bug
难度 2/5 1-3 小时 新手友好度 75/100
-
难度 2/5 1-3 小时 新手友好度 70/100