cursor-delegate-mcp 2.4.0 → 2.5.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -6,6 +6,49 @@ All notable changes to this project are documented here. The format follows
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [2.5.2] - 2026-10-15
10
+
11
+ 2.5.1 was tagged but not published: its release run failed the dependency audit. Its fix
12
+ ships in this release.
13
+
14
+ ### Security
15
+
16
+ - Lockfile bump of `proxy-addr` to 2.0.8, clearing the critical audit advisory
17
+ GHSA-jqcg-44mw-7w3h in the MCP SDK's dependencies.
18
+
19
+ ### Internal
20
+
21
+ - The release workflow also retries the MCP Registry publish on registry 5xx responses.
22
+ 2.5.0 reached npm but not the MCP Registry after a 504.
23
+
24
+ ## [2.5.1] - 2026-10-15
25
+
26
+ ### Fixed
27
+
28
+ - Hooks run on Windows under a Git Bash host. cursor-agent writes hooks as PowerShell but ran
29
+ them in Git Bash when it inherited `MSYSTEM` or `SHELL`, so every hooked tool call failed as
30
+ blocked. On win32 both are dropped from the agent's environment; it uses PowerShell.
31
+
32
+ ## [2.5.0] - 2026-10-05
33
+
34
+ ### Changed
35
+
36
+ - Zod 4. The minimum supported `@modelcontextprotocol/sdk` is now 1.23.0, the first
37
+ release that accepts Zod 4 schemas; 1.22.x requires Zod 3.
38
+
39
+ ### Security
40
+
41
+ - Lockfile bumps of `fast-uri` to 3.1.8 and `ip-address` to 10.7.3, clearing the two
42
+ moderate audit advisories in the MCP SDK's dependencies.
43
+
44
+ ### Internal
45
+
46
+ - Lockfile bumps of `@modelcontextprotocol/sdk` to 1.31.0 and the dev dependency
47
+ `@types/node` to 26.6.4.
48
+ - The release workflow retries the MCP Registry publish while npm is still processing
49
+ the new version, instead of failing the run. npm serves a new version a minute or two
50
+ after accepting it, and the registry validates against npm.
51
+
9
52
  ## [2.4.0] - 2026-10-05
10
53
 
11
54
  ### Added
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cursor-delegate-mcp",
3
- "version": "2.4.0",
3
+ "version": "2.5.2",
4
4
  "mcpName": "io.github.andreilungeanu/cursor-delegate-mcp",
5
5
  "type": "module",
6
6
  "description": "Delegate multi-file coding work from Claude Code, Codex, Copilot, or any MCP client to Cursor's CLI agent — structured results, plan mode, and changed files.",
@@ -57,8 +57,8 @@
57
57
  "typecheck": "tsc -p tsconfig.json"
58
58
  },
59
59
  "dependencies": {
60
- "@modelcontextprotocol/sdk": "^1.22.0",
61
- "zod": "^3.23.8"
60
+ "@modelcontextprotocol/sdk": "^1.23.0",
61
+ "zod": "^4.6.5"
62
62
  },
63
63
  "devDependencies": {
64
64
  "@types/node": "^26.1.1",
package/src/server.js CHANGED
@@ -85,7 +85,7 @@ export const delegateOutputShape = {
85
85
  result: z.string(),
86
86
  resultSource: z.enum(["pre-tool-fallback", "none"]).optional(),
87
87
  effectiveModel: z.string().optional(),
88
- effectiveEffort: z.record(z.string()).optional(),
88
+ effectiveEffort: z.record(z.string(), z.string()).optional(),
89
89
  stopReason: z.string().optional(),
90
90
  sessionId: z.string(),
91
91
  filesReportedByEditTools: z.array(z.string()).optional(),
@@ -146,7 +146,7 @@ export const doctorOutputShape = {
146
146
  client: z.object({
147
147
  name: z.string().nullable(),
148
148
  version: z.string().nullable(),
149
- capabilities: z.record(z.unknown()),
149
+ capabilities: z.record(z.string(), z.unknown()),
150
150
  }).passthrough(),
151
151
  agent: z.object(doctorAgentShape).passthrough(),
152
152
  runtime: z.object({
@@ -156,7 +156,7 @@ export const doctorOutputShape = {
156
156
  cwd: z.string(),
157
157
  transport: z.literal("stdio"),
158
158
  }),
159
- env: z.record(z.unknown()),
159
+ env: z.record(z.string(), z.unknown()),
160
160
  };
161
161
 
162
162
  export const delegateInputSchema = z.object({
package/src/spawn.js CHANGED
@@ -9,6 +9,17 @@ export function splitArgs(raw) {
9
9
  return args;
10
10
  }
11
11
 
12
+ // On Windows cursor-agent writes every hook command as PowerShell, but runs it in Git Bash when
13
+ // it finds MSYSTEM, or a SHELL naming Git Bash, in its environment. A host running in Git Bash
14
+ // (Claude Code on Windows) passes both down, bash rejects the PowerShell line, and the agent
15
+ // reports every hooked tool call as blocked. Dropped, the agent falls back to PowerShell, the
16
+ // shell it uses when started outside Git Bash.
17
+ const WIN32_DROPPED_ENV = new Set(["MSYSTEM", "SHELL"]);
18
+
19
+ function agentEnv(env = process.env) {
20
+ return Object.fromEntries(Object.entries(env).filter(([key]) => !WIN32_DROPPED_ENV.has(key.toUpperCase())));
21
+ }
22
+
12
23
  // shell:true on win32 is what lets a .cmd/.ps1 launcher resolve at all, and it means the
13
24
  // command and args are parsed by cmd.exe. Safe only because both come from the environment,
14
25
  // which is already as trusted as this process: anything that can set them can run code here
@@ -19,5 +30,6 @@ export function resolveAcpSpawn() {
19
30
  const args = process.env.ACP_AGENT_ARGS
20
31
  ? splitArgs(process.env.ACP_AGENT_ARGS)
21
32
  : ["acp"];
22
- return { command, args, options: { shell: process.platform === "win32" } };
33
+ const win32 = process.platform === "win32";
34
+ return { command, args, options: { shell: win32, ...(win32 ? { env: agentEnv() } : {}) } };
23
35
  }