Repository navigation
Conversation
validate-plugins.mjs rejected any marketplace entry whose source is a remote URL, even though schemas/marketplace.schema.json:68 explicitly allows 'a remote URL'. resolve(root, entry.source) turns a URL into a bogus local path that never exists, so a schema-valid marketplace with remote plugins failed validation with a misleading 'does not exist' error. Detect remote sources before resolving and skip them, so spec and tooling agree. Local paths are unaffected. Test Plan: ran scripts/validate-plugins.mjs against the repo's marketplace.json (all local sources) -> passes. Temporarily added a remote-URL entry (source: https://github.com/user/remote-test-plugin) to marketplace.json -> validator passes with my fix and would have failed with 'does not exist' without it; reverted the marketplace.json change so the diff is scripts-only. Closes cursor#640.
|
Hey @JoAdo07, same fix as #646 (opened 2026-10-16 for #640), which already has a review pass from @rahul05ranjan and handles the case-insensitive scheme. Two differences for whoever picks one: #646 prints an |
Address review feedback on cursor#714: only treat http(s) URLs as remote sources, print an INFO line when a source is skipped so the run stays visible, and move the shared check into one helper used by both the Cursor and Claude marketplace loops. The two call sites are not duplicates: the validator walks .cursor-plugin/marketplace.json and .claude-plugin/marketplace.json separately, and both need the same remote-source handling.
|
Thanks for the detailed comparison — pushed 4a7a54b with the changes:
On the duplicate block: the two call sites aren't leftovers. The validator walks Verified locally: Then I temporarily added a remote entry to each marketplace: The temporary entries were reverted. Happy for the maintainers to take either #646 or this one; this now covers both marketplaces. |
|
Hey @JoAdo07, that is the better PR now. You are right about the two call sites: the Claude marketplace loop landed on |
What changed and why
validate-plugins.mjsrejected any marketplace entry whosesourceis a remote URL, even thoughschemas/marketplace.schema.json:68explicitly allows "a remote URL".resolve(root, entry.source)turns a URL into a bogus local path (<root>/https:/github.com/user/plugin) that never exists, so a schema-valid marketplace with remote plugins failed validation with a misleading "does not exist" error andprocess.exit(1).Detect remote sources before resolving and skip them, so spec and tooling agree. Local paths are unaffected.
Failing case / reproduction (for fixes)
A marketplace.json with
{ "name": "some-plugin", "source": "https://github.com/user/some-plugin" }:validate-plugins.mjscomputesresolve(root, "https://github.com/user/some-plugin")-><root>/https:/github.com/user/some-plugin,existsSync()is false, fails withERROR: Plugin "some-plugin": source directory "https://github.com/user/some-plugin" does not existand exits 1.With the fix, remote sources are skipped and validation passes.
Verification
node scripts/validate-plugins.mjsagainst the repo'smarketplace.json(all local sources) -> passes.marketplace.json-> validator passes with the fix; would have failed with "does not exist" without it. Reverted that marketplace.json change so the diff is scripts-only.resolve('/repo', 'https://github.com/user/plugin')produces the bogus path<root>/https:/github.com/user/pluginthat the regex now avoids.Closes #640.
Note
Low Risk
Script-only change to validation behavior; remote entries are skipped rather than errored, with no impact on local plugin validation paths.
Overview
validate-plugins.mjsnow treats marketplacesourcevalues that look likehttp://orhttps://URLs as remote plugins and skips local filesystem checks instead of resolving them withpath.resolve(which produced invalid paths like<root>/https:/...and failed with “source directory does not exist”).Skipped entries log an INFO line that the remote source is not validated locally. The same skip applies in the Cursor marketplace loop, the Claude marketplace loop, and when building the map used for cross-manifest version checks. Local relative paths are unchanged.
Reviewed by Cursor Bugbot for commit 4a7a54b. Bugbot is set up for automated code reviews on this repo. Configure here.