fix(cli): stop claiming that accept merges anything
`mcpctl tasks accept --help` said "fires the merge". Nothing merges. There is no createPullRequest or mergePullRequest anywhere in the codebase — the git-provider client is task 148 and is not built. Accept records human approval and moves the task to `merged`. Until 148/149 land, `merged` means "a human approved this", not "this is in main", and the help text and service comments now say so. A user who accepted a task expecting a PR to land would have been silently wrong. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -85,7 +85,7 @@ export function createTasksCommand(deps: TasksCommandDeps): Command {
|
||||
});
|
||||
|
||||
cmd.command('accept')
|
||||
.description('Accept a task awaiting review — fires the merge')
|
||||
.description('Accept a task awaiting review (records the decision; does NOT merge the PR yet)')
|
||||
.argument('<task>', 'Task name or id')
|
||||
.option('--note <text>', 'Comment stored with the decision')
|
||||
.action(async (task: string, opts) => {
|
||||
|
||||
@@ -31,7 +31,10 @@ const TRANSITIONS: Record<TaskState, readonly TaskState[]> = {
|
||||
security_review: ['sre_review', 'done', 'in_progress', 'cancelled'],
|
||||
sre_review: ['done', 'in_progress', 'cancelled'],
|
||||
done: ['awaiting_review', 'in_progress', 'cancelled'],
|
||||
// The human gate: accept fires the merge, reject sends it back with a comment.
|
||||
// The human gate: accept records the decision, reject sends it back with a
|
||||
// comment. NOTE: accept does not yet merge anything — the git-provider merge
|
||||
// call is task 148/149. Until then `merged` means "a human approved it", not
|
||||
// "it is in main".
|
||||
awaiting_review: ['merged', 'in_progress', 'cancelled'],
|
||||
// Post-merge failure reopens; the same agent picks it back up.
|
||||
merged: ['reopened'],
|
||||
@@ -263,6 +266,10 @@ export class TaskService {
|
||||
* Accept: awaiting_review → merged. The caller's comment is stored on the
|
||||
* task, so the decision and its reason live together.
|
||||
*
|
||||
* Does NOT merge a pull request. No git-provider client is wired yet (148),
|
||||
* so this records human approval and nothing else. Anything that reads
|
||||
* `merged` as "landed in main" is currently wrong.
|
||||
*
|
||||
* This is a task-level yes/no on a resolved outcome, NOT a per-tool approval
|
||||
* — the agent has already acted autonomously up to this point.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user