Skip to content

Resolve worktree context by name

Latest

Choose a tag to compare

@Foxfire1st Foxfire1st released this 22 Jun 20:15
adbee7d

Agents Remember 2.9.3

A small but recurring resolver fix: the coordination context now resolves a worktree's contract.md from its worktree_name alone, so tooling addressed by worktree name gets the full contract context instead of empty paths.

Highlights

  • resolve_context / resolve_coordination_context now populate contract_path, code_worktree, and memory_worktree from worktree_name alone — matching what worktree_status(task_name=…) already returned (#90).

Resolver

  • resolve_contract gained a worktree_name fallback with strict precedence contract_path > task_name > worktree_name; an unmatched name returns empty rather than raising.
  • New find_worktree_contract helper enumerates tasks/<repo>/*/contract.md and matches each contract's recorded coordination.worktree_group, because worktree_name cannot be reversed to task_name (slugify preserves both - and _). The lossless join is on the worktree-group folder name.
  • find_worktree_contract is re-exported from the coordination_context_resolver facade alongside find_task_contract.

Tests

  • Happy-path regression guard (fields non-null), graceful-empty unknown name, task_name-over-worktree_name precedence, and a find_worktree_contract unit test.

Full changelog: mcp-v2.9.2...mcp-v2.9.3