You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Code Mode catalog instructs the agent to call a search(...) function inside execute to discover additional callable tools and their signatures. In this build, search is not registered in the Code Mode runtime, so every call fails with Unknown tool 'search'. The documented tool-discovery flow is unusable; agents must fall back to hard-coded catalog paths.
Observe the error (happened twice in a row, both attempts failed identically).
Expected Behavior
search(input: { query, namespace?, limit?, offset? }) should return matching catalog entries (path, description, signature) so the agent can resolve tool paths/signatures not shown in the partial catalog.
Actual Behavior
Unknown tool 'search'.
The tool may have been removed or renamed. Use search to find available tools.
The error message itself references search as the remedy, which makes the failure a dead end (the suggested tool is the one that is missing).
Additional Context
Frequency: consistently reproducible within the session (2/2 attempts).
Impact: low severity — workaround exists: call documented catalog paths directly (e.g. tools.engram.mem_save(...)). But any flow that depends on discovering tool signatures beyond the visible catalog is blocked. In our case the agent could not locate the mem_judge tool of the engram MCP server to resolve conflict candidates after mem_save.
The Code Mode system prompt/catalog explicitly documents search(...) as callable, so docs and runtime disagree.
Thanks for the report. We can't reproduce this as described because the version, invocation, and error do not line up with the shipped runtimes:
In OpenCode 1.18.30's experimental Code Mode, discovery is exposed as tools.$codemode.search(...). Calling bare search(...) there would fail as an unknown identifier, not as Unknown tool 'search'.
In OpenCode V2, discovery is the bare built-in search(...). The exact error quoted here is what V2 returns when tools.search(...) is called instead.
So the reported bare search(...) snippet and the quoted error cannot originate from the same official runtime described in the environment. The environment also lists both the 1.18.30 release and a 0.0.0-beta-19242 runtime snapshot, which suggests the CLI, background service, harness, or captured invocation may be coming from different installations.
Closing as can't reproduce. If this still occurs, please provide the raw execute input and complete output, together with the version reported by the process/background service actually handling that session. That would let us identify which runtime is executing the call.
Activity
github-actions commentedon Sep 14, 2026
This issue might be a duplicate of an existing issue. Please check:
Unknown tool 'search'error in Code Mode's tool-discovery helper — covers the discrepancy between documented invocation forms and what's actually registered at runtime, which matches the failure you're seeing on 1.18.30.opencode-agent commentedon Sep 14, 2026
Thanks for the report. We can't reproduce this as described because the version, invocation, and error do not line up with the shipped runtimes:
tools.$codemode.search(...). Calling baresearch(...)there would fail as an unknown identifier, not asUnknown tool 'search'.search(...). The exact error quoted here is what V2 returns whentools.search(...)is called instead.So the reported bare
search(...)snippet and the quoted error cannot originate from the same official runtime described in the environment. The environment also lists both the 1.18.30 release and a0.0.0-beta-19242runtime snapshot, which suggests the CLI, background service, harness, or captured invocation may be coming from different installations.Closing as can't reproduce. If this still occurs, please provide the raw
executeinput and complete output, together with the version reported by the process/background service actually handling that session. That would let us identify which runtime is executing the call.