[Feature] Treat unknown or wrong-case names in [tools] disabled/enabled as errors

Đang mở
#4,037 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
68/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
typescript
Lĩnh vực
cli, tooling

Hướng nghiên cứu

Start by locating the validation for the [tools].disabled and [tools].enabled configuration, then compare it with the configuration docs' tools section. Preserve exact-name matching and empty enabled-list behavior; done means unmatched, malformed, or wrong-case names fail with the existing warning text while naming the relevant entry or exact built-in name.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

What feature would you like to see?

When [tools].disabled (or [tools].enabled) contains a name that matches no built-in tool and no MCP tool, fail loudly — exit with an error or refuse to start the session — instead of only printing a warning.

Matching is case-sensitive today, so disabled = ["agent"] does not disable Agent, and the tool silently stays available.

Concretely: keep the current warning text, but make it a hard failure for the three shapes the docs already say never match:

  • a wildcard that is not an mcp__ pattern,
  • an mcp__ name missing the tool segment,
  • any name that no registered tool has.
Additional information

The configuration docs (tools section) say those shapes "are reported with a warning" and that matching is case-sensitive. A denylist that is silently inert after a one-character case mistake is exactly how a session keeps a tool the operator tried to turn off — including Agent and AgentSwarm.

Behaviour that should keep working: exact names such as disabled = ["Agent", "AgentSwarm"], and an empty enabled list still meaning "no allowlist constraint", as documented.

Suggested acceptance check: with disabled = ["agent"] the process refuses to run and the message suggests the exact built-in name Agent; with disabled = ["NoSuchTool"] it refuses and names the unmatched entry.

Ngôn ngữ chính
TypeScript
Star
8.1k
Fork
1.3k
Merge trung bình
17 giờ 41 phút
Pull request đã merge (30 ngày)
172

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. 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.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của MoonshotAI/kimi-code

Tất cả issue của MoonshotAI/kimi-code

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.