Skip to content

fix(agents): recognize core tools that carry metadata in policy pipeline - #45293

Closed
huangmingche wants to merge 10000 commits into
openclaw:mainfrom
huangmingche:fix/core-tool-with-metadata-classification
Closed

huangmingche wants to merge 10000 commits into
openclaw:mainfrom
huangmingche:fix/core-tool-with-metadata-classification

Conversation

@huangmingche

Copy link
Copy Markdown

The tool-policy pipeline builds a coreToolNames set by checking !toolMeta(tool), which assumes core tools never have metadata. But tools like apply_patch are registered in the core tool catalog while also carrying metadata (provider-specific). This caused them to be classified as plugin-only during allowlist sanitization, so agent-routed runs couldn't execute them.

Added a fallback to isKnownCoreToolId so the filter catches both cases. Also added a test covering core-tool-with-metadata specifically.

Fixes #45269

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling size: XS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: apply_patch is treated as an unknown/plugin-only tool in agent policy pipeline, so agent-routed runs cannot execute it