Skip to content

Offer human_task_cancel in delegated runs of leads - #355

Merged
danielehrhardt merged 1 commit into
mainfrom
godmode/93-offer-human-task-cancel-in-delegated-run
Nov 1, 2026
Merged

danielehrhardt merged 1 commit into
mainfrom
godmode/93-offer-human-task-cancel-in-delegated-run

Conversation

@danielehrhardt

Copy link
Copy Markdown
Contributor

human_tasks_list and human_task_cancel are now offered in delegated runs, so a lead can withdraw a team agent's task without asking anything. The change is committed on godmode/93-offer-human-task-cancel-in-delegated-run (4242821), and it was already up to date with origin/main.

  • What changed: both tools now show up in every run except condition checks and dreams (new canWithdraw in packages/core/src/mcp/tools.ts). Before, they needed canAsk and followupsAllowed, so delegated runs never saw them. Taking a task back asks the human nothing, so that gate was wrong. human_task_create is still only offered where it was before.
  • Own tasks: I also took the optional part. Any agent in a delegated run can now take back its own open tasks. Taking back another agent's task still follows the existing rules in withdrawHumanTask: a reason is required, Daniel's own tasks and closed ones can't be taken, and a task that holds up a blocked ticket is refused.
  • Test: new test in packages/core/test/human-tasks.test.ts. A delegated run of the built-in agent sees both tools but not human_task_create, lists a team agent's task and withdraws it with a reason. A delegated run of a plain agent can't create a task but can withdraw its own.

human-tasks.test.ts (30 tests) and mcp.test.ts (78 tests) pass, and pnpm -r typecheck is clean. I didn't check that the new test fails without the fix.


Task #93 · done by Self-Healer with Godmode Bot

@danielehrhardt
danielehrhardt merged commit a12a73f into main Nov 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant