Skip to content

fix: harden plugin creator sharing validation#22893

Merged
efrazer-oai merged 2 commits into
mainfrom
fix/plugin-creator-share-validator
May 18, 2026
Merged

fix: harden plugin creator sharing validation#22893
efrazer-oai merged 2 commits into
mainfrom
fix/plugin-creator-share-validator

Conversation

@efrazer-oai
Copy link
Copy Markdown
Contributor

Summary

Before this change, the sample plugin creator could emit placeholder-heavy manifests that fail workspace sharing, and it chose a repo-local marketplace implicitly whenever it ran from inside a git checkout.

This PR makes generated plugins share-ready by default. It switches creation to the personal marketplace unless the caller explicitly opts into repo-local paths, adds a validator that mirrors the workspace plugin ingestion contract, and updates the skill prompt and docs to describe the real flow.

The goal is to stop malformed generated plugins before they reach sharing and to make the default placement match the personal marketplace behavior users expect.

Changes

  • Generate share-safe plugin manifests instead of [TODO: ...] placeholder payloads.
  • Default plugin and marketplace creation to ~/plugins and ~/.agents/plugins/marketplace.json.
  • Keep repo-local marketplace creation available through explicit --path and --marketplace-path arguments.
  • Add validate_plugin.py to check manifests, companion files, skill frontmatter, skill agent YAML, asset paths, and backend-shaped contracts before sharing.
  • Refresh the plugin creator skill text, reference docs, and default prompt to describe validation and the personal default.

Design decisions

  • The validator tracks the workspace ingestion schema directly, including the required defaultPrompt alias handling and skill agents/openai.yaml checks.
  • The validator keeps one intentional extra preflight rule: leftover [TODO: ...] placeholders are rejected before sharing even when a single placeholder would not independently violate backend type validation.
  • Repo-local creation stays possible, but it is now explicit instead of cwd-sensitive.

Testing

Tests: targeted Python syntax checks, plugin skill validation, staged diff whitespace validation, 15 generated plugin smoke runs, backend manifest-schema acceptance for all 15 generated bundles, and a git-repo cwd regression proving the creator still writes to the personal marketplace by default.

@efrazer-oai efrazer-oai force-pushed the fix/plugin-creator-share-validator branch from 8330cde to 80d9c99 Compare May 15, 2026 20:40
@efrazer-oai efrazer-oai requested a review from xl-openai May 15, 2026 20:43
@efrazer-oai efrazer-oai marked this pull request as ready for review May 15, 2026 20:43
- Personal plugin: `~/.agents/plugins/marketplace.json`
- Repo/team plugin: `<repo-root>/.agents/plugins/marketplace.json`

### Workspace sharing notes
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we should treat this as a general guidance, not just for sharing?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Revised!

@efrazer-oai efrazer-oai requested a review from xl-openai May 18, 2026 16:43
@efrazer-oai efrazer-oai merged commit d32cb2c into main May 18, 2026
31 checks passed
@efrazer-oai efrazer-oai deleted the fix/plugin-creator-share-validator branch May 18, 2026 18:22
@github-actions github-actions Bot locked and limited conversation to collaborators May 18, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants