From 72553446d55c8309d165925b6b4e3665f0308426 Mon Sep 17 00:00:00 2001 From: Joe Davis Date: Fri, 12 Jun 2026 15:27:06 -0700 Subject: [PATCH 1/2] Fix pipeline friction: permissions, branch setup, skill file access - Pre-approve common git/script commands in ~/.claude/settings.json to eliminate repeated approval prompts for get-context-path.sh and git ops - Add setting-up pipeline state + SetupWorkspaceStep: finds epic branch via spec/Jira, pulls latest, creates dev/claude/ before research - Fix task-runner to embed skill content in sub-agent prompt (reads skill file itself and substitutes $TASK_BRIEF/$ARGUMENTS/etc.) so sub-agents no longer need plugin-dir file access via the Skill tool - Fix developer-implement step 0: check for exact dev/claude/ branch name instead of loose "contains work-item-id" which matched feature branches - Simplify branch naming: drop slug suffix, use dev/claude/ only - Pass plugin_root to task-runner so it knows where to load skill files from Co-Authored-By: Claude Sonnet 4.6 --- plugins/dev-team/agents/task-runner.md | 43 ++++++------ plugins/dev-team/agents/workspace-setup.md | 15 ++++ plugins/dev-team/commands/create-branch.md | 22 +++--- plugins/dev-team/commands/dev-team.md | 1 + .../dev-team/commands/developer-implement.md | 10 +-- plugins/dev-team/commands/workspace-setup.md | 68 +++++++++++++++++++ plugins/dev-team/scripts/dev_team.py | 43 ++++++++++++ .../dev-team/scripts/implement-task-plan.md | 3 +- 8 files changed, 165 insertions(+), 40 deletions(-) create mode 100644 plugins/dev-team/agents/workspace-setup.md create mode 100644 plugins/dev-team/commands/workspace-setup.md diff --git a/plugins/dev-team/agents/task-runner.md b/plugins/dev-team/agents/task-runner.md index 65fbf5f..faa3cea 100644 --- a/plugins/dev-team/agents/task-runner.md +++ b/plugins/dev-team/agents/task-runner.md @@ -27,7 +27,8 @@ Parse the following fields from your prompt: - `agent` — sub-agent type to spawn via the `Agent` tool (used for display/logging in the context header only; does not affect routing or tool selection) -- `skill` — name of the skill the sub-agent should invoke +- `skill` — name of the skill the sub-agent should execute +- `plugin_root` — absolute path to the dev-team plugin directory (used to load skill files) - `context_file` — absolute path to the pipeline context file - `args` — (optional) positional arguments to present to the skill - `read_sections` — comma-separated list of section names to read from the context file @@ -40,30 +41,32 @@ Use the `Read` tool to read `context_file`. Extract the content of each section `read_sections`. A section begins at `` and ends at the next `", "", self.workspace_setup.strip()] + if self.debug_report: lines += ["", "", "", self.debug_report.strip()] @@ -308,6 +312,7 @@ def load(cls, path: Path) -> "PipelineContext": pass sections = _parse_sections(body) + ctx.workspace_setup = sections.get("Workspace Setup", "") ctx.debug_report = sections.get("Debug Report", "") ctx.brief = sections.get("Researcher Brief", "") @@ -502,6 +507,43 @@ def handle_results(self) -> str: ... +class SetupWorkspaceStep(Step): + handles = "setting-up" + _PENDING_KEY = "setup" + + def __init__(self, ctx: "PipelineContext", context_path: Path) -> None: + self._ctx = ctx + self._context_path = context_path + + def get_actions(self) -> list[dict]: + ctx = self._ctx + if ctx.workspace_setup: + return [] + return [{ + "action": "spawn_agent", + "message": f"Setting up workspace branch for {ctx.work_item_id}.", + "agent": "workspace-setup", + "skill": "workspace-setup", + "args": f"{ctx.work_item_id} {ctx.spec_path}", + "context_file": str(self._context_path), + "read_sections": [], + "write_section": "Workspace Setup", + "result_format": "setup_done | failed", + }] + + def handle_results(self) -> str: + ctx = self._ctx + if ctx.workspace_setup: + _handle_agent_success(ctx) + return "setup_done" + _handle_agent_failure(ctx) + _check_and_trigger_troubleshooter( + "consecutive_failures", CONSECUTIVE_FAILURES_THRESHOLD, + ctx.consecutive_failures, ctx, self._context_path, + ) + return "failed" + + class FindSpecStep(Step): handles = "spec-finding" @@ -1125,6 +1167,7 @@ def __init__( self.machine = StateMachine(workflow.transitions, initial=ctx.state) self.step_handlers: dict[str, Step] = { "spec-finding": FindSpecStep(ctx), + "setting-up": SetupWorkspaceStep(ctx, context_path), "debugging": DebugStep(ctx, context_path), "researching": ResearchStep(research_skill, ctx, context_path), "implementing": ImplementStep(ctx, context_path), diff --git a/plugins/dev-team/scripts/implement-task-plan.md b/plugins/dev-team/scripts/implement-task-plan.md index 5af8961..33774ea 100644 --- a/plugins/dev-team/scripts/implement-task-plan.md +++ b/plugins/dev-team/scripts/implement-task-plan.md @@ -2,7 +2,8 @@ stateDiagram-v2 [*] --> init init --> spec-finding : start - spec-finding --> researching : spec_found + spec-finding --> setting-up : spec_found + setting-up --> researching : setup_done researching --> implementing : research_done implementing --> validating : impl_done validating --> fixing : build_failed From 8ab5d719fae4a9ad97392c40867b536e117832d9 Mon Sep 17 00:00:00 2001 From: Claude Code acting for jodavis Date: Fri, 12 Jun 2026 15:45:13 -0700 Subject: [PATCH 2/2] Update dev-team version to 1.2.3 --- plugins/dev-team/.claude-plugin/plugin.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/dev-team/.claude-plugin/plugin.json b/plugins/dev-team/.claude-plugin/plugin.json index 34817c6..2b086ea 100644 --- a/plugins/dev-team/.claude-plugin/plugin.json +++ b/plugins/dev-team/.claude-plugin/plugin.json @@ -1,6 +1,6 @@ { "name": "dev-team", - "version": "1.2.2", + "version": "1.2.3", "description": "Dev-team agent pipeline: researcher, developer, reviewer, and debugger agents for implementing Jira tasks and fixing GitHub issues.", "commands": "./commands" }