Skip to content

Issues when importing custom agents with tools (due to incompatible tools format) #9305

@rafael-unloan

Description

@rafael-unloan

Hi, I'm trying to reuse a custom agent by importing it, for e.g.:

imports:
  - ../agents/feature-flag-remover.agent.md

This agent specifies the following tools:

---
description: "Blah"
tools:
  [
    "edit",
    "search",
    "execute/getTerminalOutput",
    "execute/runInTerminal",
    "read/terminalLastCommand",
    "read/terminalSelection",
    "execute/createAndRunTask",
    "execute/getTaskOutput",
    "execute/runTask",
    "read/problems",
    "search/changes",
    "agent",
    "runTasks",
    "problems",
    "changes",
    "runSubagent",
  ]
---

Error during gh aw compile:

⚠ Invalid configuration in /my-repo/.github/agents/feature-flag-remover.agent.md: .github/agents/feature-flag-remover.agent.md:3:7: error: at '/tools': got array, want object. Expected format: {"bash":null,"cache-memory":null,"playwright":null}

Ignoring that error message, I've also tried actually using that Agentic workflow, but it just results in tool issues. For instance,safe-outputs.create-pull-request doesn't work anymore, complains that it does not exist.

safe-outputs:
  create-pull-request:
    title-prefix: "chore(feature-flag-cleanup): "
    labels: [feature-flag-cleanup, automation]
    draft: true

Should gh aw ignore the tool property of custom agents? Since the tools in custom agents is an array vs tools in the workflow is an object. And conceptually, it'd make sense that only the workflow tools takes effect.

Metadata

Metadata

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions