fix(mcp): support custom issue types and statuses (#1023)

Change IssueType and IssueStatus from Literal to str to support
custom types configured via:
  bd config set types.custom "agent,molecule,event"
  bd config set status.custom "awaiting_review,awaiting_testing"

The CLI handles validation of these values against the configured
options. The MCP layer is just a transport and shouldn't re-validate
what the CLI already validates.

This fixes Pydantic validation errors when listing issues that have
custom types like 'event', 'molecule', or 'agent'.

Built-in types: bug, feature, task, epic, chore
Built-in statuses: open, in_progress, blocked, deferred, closed
This commit is contained in:
Marvin Bitterlich
2026-01-12 02:17:01 +00:00
committed by GitHub
parent d04bffb9b6
commit 68da7c9f78
4 changed files with 20 additions and 11 deletions

View File

@@ -383,9 +383,9 @@ async def get_tool_info(tool_name: str) -> dict[str, Any]:
"name": "list",
"description": "List all issues with optional filters",
"parameters": {
"status": "open|in_progress|blocked|deferred|closed (optional)",
"status": "open|in_progress|blocked|deferred|closed or custom (optional)",
"priority": "int 0-4 (optional)",
"issue_type": "bug|feature|task|epic|chore (optional)",
"issue_type": "bug|feature|task|epic|chore or custom (optional)",
"assignee": "str (optional)",
"labels": "list[str] (optional) - AND filter: must have ALL labels",
"labels_any": "list[str] (optional) - OR filter: must have at least one",
@@ -421,7 +421,7 @@ async def get_tool_info(tool_name: str) -> dict[str, Any]:
"title": "str (required)",
"description": "str (default '')",
"priority": "int 0-4 (default 2)",
"issue_type": "bug|feature|task|epic|chore (default task)",
"issue_type": "bug|feature|task|epic|chore or custom (default task)",
"assignee": "str (optional)",
"labels": "list[str] (optional)",
"deps": "list[str] (optional) - dependency IDs",
@@ -436,7 +436,7 @@ async def get_tool_info(tool_name: str) -> dict[str, Any]:
"description": "Update an existing issue",
"parameters": {
"issue_id": "str (required)",
"status": "open|in_progress|blocked|deferred|closed (optional)",
"status": "open|in_progress|blocked|deferred|closed or custom (optional)",
"priority": "int 0-4 (optional)",
"assignee": "str (optional)",
"title": "str (optional)",