fix: error handling of task status settings (#523)

* fix: error handling of task status settings

* fix: update import path

---------

Co-authored-by: shenysun <shenysun@163.com>
This commit is contained in:
Ralph Khreish
2025-05-16 15:47:01 +02:00
committed by GitHub
parent ed17cb0e0a
commit da317f2607
8 changed files with 92 additions and 3 deletions

View File

@@ -11,6 +11,7 @@ import {
} from './utils.js';
import { setTaskStatusDirect } from '../core/task-master-core.js';
import { findTasksJsonPath } from '../core/utils/path-utils.js';
import { TASK_STATUS_OPTIONS } from '../../../src/constants/task-status.js';
/**
* Register the setTaskStatus tool with the MCP server
@@ -27,7 +28,7 @@ export function registerSetTaskStatusTool(server) {
"Task ID or subtask ID (e.g., '15', '15.2'). Can be comma-separated to update multiple tasks/subtasks at once."
),
status: z
.string()
.enum(TASK_STATUS_OPTIONS)
.describe(
"New status to set (e.g., 'pending', 'done', 'in-progress', 'review', 'deferred', 'cancelled'."
),