Repository navigation
Conversation
This was referenced Nov 16, 2026
The resolver recognizes Agent Plugins (agent-plugins.org, spec 1.0.0) directories when ResolveOptions.PluginsEnabled is set and emits them as KindPlugin resources. Resolve, and the Manager until a later change wires the flag, keep plugin discovery off. Skills bundled in a plugin are loaded by the next change. Discovery: a plugin is an immediate child of plugins/ or .agents/plugins/ under a scan root, or a scan root that itself holds a plugin.json. A plugin.json at a scan root or in plugins/ whose $schema is absent or not an https://agent-plugins.org/schemas/ URL may belong to another tool and is ignored after a debug log. In .agents/plugins/ every plugin.json is taken as an Agent Plugins manifest and every problem is reported as an invalid plugin with the reason. Validation follows spec section 5: name grammar (via workspacesdk.ValidatePluginName), optional string fields, keywords as strings, closed author object, extensions as object. Unknown top-level fields are recorded in Resource.Error while the status stays OK; other violations reject the plugin. Version and description are stripped of U+0000 and capped at 64 and 1024 runes. The plugin root is canonicalized once and is the containment boundary for plugin.json, which may be a symlink that resolves inside the root. Symlinked plugin directories and plugin containers are skipped, as are paths longer than workspacesdk.MaxContextSourceBytes or names that are not valid UTF-8. Co-Authored-By: Claude Opus 5.5 <[email protected]>
f0ssel
force-pushed
the
garrett/agent-plugins/02-plugin-discovery
branch
from
November 16, 2026 22:43
3809fca to
e0d2354
Compare
f0ssel
commented
Nov 16, 2026
parsePluginManifest decodes the schema-defined keys into a struct instead of checking each field by hand. manifestString rejects JSON null, which encoding/json would otherwise treat as absent, and only the exact schema keys are decoded because encoding/json matches keys case-insensitively. readPluginManifest returns the file and a *resourceError instead of writing status and error through a *Resource. withoutNUL replaces the inline U+0000 stripping shared by skills and plugin manifests. The plugin tests for invalid UTF-8 names and long paths no longer assert on plugin skills, which the next change loads; they only run on Linux, so local macOS runs missed it. Co-Authored-By: Claude Opus 5.5 <[email protected]>
f0ssel
force-pushed
the
garrett/agent-plugins/02-plugin-discovery
branch
from
November 16, 2026 23:25
fbc413f to
fe9eddc
Compare
Member
Author
|
@codex review |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex Review: Didn't find any major issues. Breezy! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
…t/agent-plugins/02-plugin-discovery
This branch has not been deployed
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.
The
agentcontextresolver recognizes Agent Plugins (agent-plugins.org, spec 1.0.0) whenResolveOptions.PluginsEnabledis set: each child ofplugins/or.agents/plugins/under a scan root, or a scan root holding aplugin.json. Manifests are validated against spec section 5, andplugin.jsonmust resolve inside the canonical plugin root. Skills bundled in a plugin are loaded by #32296. Resources are deduplicated onSource(coderd rejects repeats), skills on(plugin, name), and the snapshot is capped atMaxContextResources. The built-in~/.claude/plugins/cachescan root is removed.Discovery stays off in this PR; the Manager passes
ResolveOptions{}until the next PR wires the manifest flag. About 1k of the ~1.95k added lines are tests.Part 2 of the #29321 split.
Stack (base
main, replaces #29321–#30577):Generated by Claude Code