Skip to content

fix(cursor): honest workspace/open, real marketplace, three-host composite intersection - #221

Merged
ScriptedAlchemy merged 1 commit into
mainfrom
fix/cursor-capability-corrections
Sep 1, 2026
Merged

fix(cursor): honest workspace/open, real marketplace, three-host composite intersection#221
ScriptedAlchemy merged 1 commit into
mainfrom
fix/cursor-capability-corrections

Conversation

@ScriptedAlchemy

Copy link
Copy Markdown
Owner

Summary

Fixes the three Cursor capability defects from the docs-coverage audit (#189) and the #173 review thread, on top of the #194 dispatch rework and the #100 s2 rules (#207) / commands (#219) merges.

  1. workspace/open flipped to unavailable on Cursor (Refresh Cursor plugin contract coverage against current public docs #189). Cursor's native workspaceOpen hook is sessionless — it fires outside an agent session with no session/conversation fields — and its response must return pluginPaths. Both generated Cursor wrappers (cursorHookWrapperSource and the event-route wrapper) hard-require session_id/conversation_id on stdin and have no output channel for pluginPaths, so the previous supported claim was false and Refresh Cursor plugin contract coverage against current public docs #189 forbids retaining it without a real-envelope fixture. The capability row now carries the precise reason, workspaceOpen is removed from the plain-hook event map (a plain hook now gets a cursor.hook.event.workspace-open diagnostic instead of silently lowering a broken wrapper), and the workspace/open family stays defined but unavailable on every host. Docs matrix and provenance evidence updated; capability sha repinned.

  2. Cursor marketplace corrected to supported with evidence (Refresh Cursor plugin contract coverage against current public docs #189). .cursor-plugin/marketplace.json is real: schemas/marketplace.schema.json exists in cursor/plugins at the exact commit PR fix(cursor): conform local plugin artifacts to real host #131 pinned for the plugin schema (0701892). The official schema is now vendored (sha256 1aae96a2…, PROVENANCE updated), the cursor target and the unified bundle emit a schema-validated marketplace document when marketplace: true, and the capability row is supported with pinned evidence.

  3. Plugin composite capabilities now intersect Cursor (feat(events): publish host family capability states #173 review thread, still present post-fix(events): correct Claude and Codex subagent hooks #194). compositeEventCapabilities intersected Claude ∩ Codex only while the bundle plan also emits Cursor manifests, hooks, and MCP documents. Event families now intersect all three pinned host tables (failing closed at module init if any table diverges in route keys), and the scalar rows the bundle emits for all three hosts (marketplace, hooks, mcp, skills, plus the newly-landed commands and rules) intersect Cursor as well. lsp stays Claude ∩ Codex because Cursor declares no LSP surface at all; the comment says so.

Evidence

  • cursor/plugins@0701892 schemas/marketplace.schema.json (raw fetch, sha256 1aae96a24c2796419933bc8bfe3a1255394e7199c35740b36325e0ce6dbc253d)
  • https://cursor.com/docs/agent/hooks (workspaceOpen sessionless + pluginPaths, observed 2026-09-01)
  • Generated wrapper contracts in hook-contract.ts (session-id validation, no pluginPaths output vocabulary)

Test plan

  • Scoped suites over every touched surface (adapter-capability-states, adapter-metadata, cursor-adapter, host-adapters, plugin-bundle, route-graph, event-project, hook-playground-service, target-hook-contract): 62/62 pass
  • fix(events): correct Claude and Codex subagent hooks #194 regression bar (event-project + hook playground + hook contract) green
  • pnpm test:route-unit 11/11, pnpm test:projection 23/23
  • pnpm typecheck, pnpm lint clean
  • Full test:unit pool: only environment-flaky suites fail (scaffold-packed-matrix.e2e, native-claude-contract, etc.) — verified identical failures on a clean origin/main worktree in this environment
  • Patch changeset included

Closes the two #189 checklist rows for marketplace and workspaceOpen; replies posted on #189 and the #173 review thread.

@changeset-bot

changeset-bot Bot commented Sep 1, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 623f7f3

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
agent-bundle Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 1, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-01T22:08:47.913988Z e585695 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@pkg-pr-new

pkg-pr-new Bot commented Sep 1, 2026

Copy link
Copy Markdown
npm i https://pkg.pr.new/ScriptedAlchemy/agent-bundle@221
npm i https://pkg.pr.new/ScriptedAlchemy/agent-bundle/create-agent-bundle@221
npm i https://pkg.pr.new/ScriptedAlchemy/agent-bundle/@agent-bundle/runtime@221

commit: 9078abc

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: e585695234

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

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".

claudeAdapter.capabilities[capability]!,
codexAdapter.capabilities[capability]!,
),
cursorAdapter.capabilities[capability]!,

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Add Cursor to the bundle capability fingerprint

Once this line makes the plugin capability state depend on cursorAdapter, the plugin target metadata at lines 177–181 is no longer an accurate fingerprint: its revision strings still mention only Claude and Codex, while capabilitySha256 is only Claude's hash. Consequently, generated agent-bundle.manifest.json files misstate the evidence behind these three-host capability claims, and matchesTargetMetadata cannot detect a Cursor-only capability-table correction at the same observed version unless an unrelated schema or output also changes. Derive the composite metadata from all three host pins and bump the plugin adapter revision.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

Fixed. The plugin metadata now derives its fingerprint from all three host pins: capabilityRevision/observedVersion name claude, codex, and cursor, and capabilitySha256 is sha256Hex(stableJson([...])) over the three per-host capability hashes, so a Cursor-only capability-table correction at the same observed version changes the manifest identity. Adapter revision bumped to 1.4.0.

@ScriptedAlchemy
ScriptedAlchemy force-pushed the fix/cursor-capability-corrections branch from e585695 to 9078abc Compare September 1, 2026 22:26
…osite intersection

- Flip workspace/open to unavailable on Cursor: the native workspaceOpen hook
  fires outside an agent session and must return pluginPaths, an envelope the
  generated session-scoped wrapper vocabulary cannot express (#189).
- Mark Cursor marketplace supported: pin the official marketplace.schema.json
  from cursor/plugins@0701892 and emit a schema-validated
  .cursor-plugin/marketplace.json from the cursor target and the bundle (#189).
- Intersect Cursor into the plugin composite event and scalar capabilities so
  the bundle's states reflect every host it emits for (#173 review thread).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant