Repository navigation
fix(agystack): grant oneharness tools and inheritMcp to poteto-agent - #18
Merged
jtaroreh merged 2 commits intoNov 21, 2026
Merged
Conversation
Custom markdown agents that omit tools receive a read-only default set in Antigravity, while listing Cortex MCP wrappers inside tools crashes oneharness executor construction.
Without explicit oneharness tool declarations and inheritMcp, poteto-agent spawns without file-edit, shell, subagent, or MCP access and blocks delegated code modifications.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
In Google Antigravity, custom markdown agents in
agents/*.mdthat omittoolsreceive only a five-tool read-only default set and keepinheritMcpdisabled. Becauseagents/poteto-agent.mdomitted both fields, everypoteto-agentspawned under the Subagent Delegation Invariant lackededit_file,write_file,run_command,manage_task,invoke_subagent,manage_subagents,define_subagent,ask_question, and MCP access, blocking delegated code changes at startup.At the same time, Antigravity resolves static
toolsentries against theoneharnesstool registry while Cortex attachescall_mcp_tool,list_resources, andread_resourcedynamically wheninheritMcpistrue. Listing those three MCP tool names directly insidetoolsfails executor construction withunknown component: tool "call_mcp_tool" not found in registry.Scope
agents/poteto-agent.mdfrontmatter to setinheritMcp: trueand grant the 13oneharnesstools required for code modification, command execution, subagent coordination, and user questions:read_file,edit_file,write_file,run_command,manage_task,send_message,schedule,invoke_subagent,manage_subagents,define_subagent,ask_question,search_web, andgenerate_image.parse_frontmatterintests/test_agent_definitions.pyto enforce line-anchored---fences, strip unquoted#comments, and parse single-line flow lists, multiline flow lists, and-block lists.test_poteto_agent_grants_execution_and_mcp_capabilitiesandtest_custom_agents_only_declare_registered_oneharness_toolsintests/test_agent_definitions.pyto pinREQUIRED_POTETO_AGENT_TOOLS,VALID_ONEHARNESS_AGENT_TOOLS, duplicate-tool checks, and the ban onDYNAMIC_CORTEX_MCP_TOOLSinsidetools.agents/comment-sicko.mdunchanged so it retains the read-only reviewer behavior documented inREADME.mdandskills/poteto-mode/references/antigravity-tools.md.Tradeoffs
tests/test_agent_definitions.pyparses frontmatter lists with Python's standard library rather than addingPyYAMLtopyproject.toml. Keeping test dependencies unchanged avoids adding a third-party parser for nine lines of agent metadata.Blast Radius
agents/poteto-agent.mdandtests/test_agent_definitions.pychange.TypeName: "poteto-agent"gain file-mutation, command-execution, subagent-orchestration, and inherited MCP capabilities within the existingcommandExecutionPolicy: sandboxandinheritCustomizations: falseboundaries.main, every coordinator session that delegates edits over 50 lines topoteto-agenthits a read-only subagent block and has to fall back to ad-hoc agent definitions orself.Verification
poteto-agentsessions whentoolsis omitted andunknown component: tool "call_mcp_tool" not found in registrywhen MCP wrapper names appear intools.GetAllPluginsRPC and live subagent invocation, confirming all 13oneharnesstools pluscall_mcp_tool,list_resources, andread_resourceload cleanly with zero executor errors.pytest -v tests/test_agent_definitions.pyagainstorigin/mainbefore applying theagents/poteto-agent.mdcommit and confirmedtest_poteto_agent_grants_execution_and_mcp_capabilitiesfailed as expected.ruff check .passed,pytest -v tests/test_plugin_manifest.pypassed,python skills/setup-agystack/scripts/setup_runtime.py --doctorreturned"status": "OK",pytest -v --timeout=60 tests/passed 394 tests with 153 subtests, andbun testinskills/poteto-mode/scriptspassed all 47 tests.