cursor-feedback 2.0.3 → 2.0.4

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
@@ -2,6 +2,13 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [2.0.4](https://github.com/jianger666/cursor-feedback-extension/compare/v2.0.3...v2.0.4) (2026-06-22)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * **mcp:** 反馈归属只取 AI 传入的 project_directory,不再被 WORKSPACE_FOLDER_PATHS 带偏 ([b43975f](https://github.com/jianger666/cursor-feedback-extension/commit/b43975f772651725569bb0e578937ef8a52683c9))
11
+
5
12
  ### [2.0.3](https://github.com/jianger666/cursor-feedback-extension/compare/v2.0.2...v2.0.3) (2026-06-22)
6
13
 
7
14
 
@@ -104,10 +104,6 @@ class McpFeedbackServer {
104
104
  // 所属工作区(只在 AI 调用 feedback 时设置)
105
105
  // 只有来自同一工作区的轮询才会更新活动时间
106
106
  this.ownerWorkspace = null;
107
- // Cursor 在 spawn 本 MCP server 时注入的「真实所属工作区」,精确指向发起对话的那个窗口。
108
- // 这是可靠的归属信号:AI 传的 project_directory 可能被填成对话里聊到的另一个项目,
109
- // 用它路由会把反馈发到错误窗口、当前窗口收不到(用户反馈的 bug)。拿不到时回退到 AI 传参。
110
- this.realWorkspace = (process.env.WORKSPACE_FOLDER_PATHS || '').split(',')[0].trim() || null;
111
107
  // Server 启动时间
112
108
  this.startTime = Date.now();
113
109
  // 最近一次活动时间(任意 HTTP 轮询 / MCP 调用都会刷新)
@@ -239,9 +235,10 @@ class McpFeedbackServer {
239
235
  isError: true,
240
236
  };
241
237
  }
242
- // 归属以 Cursor 注入的真实工作区为准(修复:AI project_directory 传成对话里聊到的
243
- // 另一个项目时,反馈会发到错误窗口、当前窗口收不到)。拿不到 env 时才回退到 AI 传参。
244
- const projectDir = this.realWorkspace || args.project_directory;
238
+ // 归属直接用 AI 每轮传入的 project_directory(精确指向当前发起对话的窗口)。
239
+ // 不读 WORKSPACE_FOLDER_PATHS:那是进程级固定值,多窗口共享 / 复用同一个 MCP 进程时只反映
240
+ // 「首个拉起进程的窗口」,会把反馈发错窗口、当前窗口收不到(用户反馈的 bug)。
241
+ const projectDir = args.project_directory || '';
245
242
  // summary 支持别名 message
246
243
  const summary = args?.summary || args?.message || '我已完成您的请求。';
247
244
  // 超时时间优先级:环境变量 > 工具参数 > 默认值(300秒)
@@ -761,7 +758,7 @@ class McpFeedbackServer {
761
758
  // 别的活跃窗口对全端口的扫描虽刷 lastActivityTime,但 workspace 不匹配、不刷此字段,
762
759
  // 故已关窗口的残留 server 不会被别人续命,可被 watchdog / 僵尸自检识别。
763
760
  const ws = this.normalizePath(u.searchParams.get('workspace') || '');
764
- if (ws && (ws === this.ownerWorkspace || ws === this.normalizePath(this.realWorkspace || ''))) {
761
+ if (ws && ws === this.ownerWorkspace) {
765
762
  this.lastOwnerPollTime = Date.now();
766
763
  this.everOwnerPolled = true;
767
764
  }
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "cursor-feedback",
3
3
  "displayName": "Cursor Feedback",
4
4
  "description": "One Cursor conversation, unlimited AI interactions - Save your monthly request quota! Interactive feedback loop for AI chat via MCP",
5
- "version": "2.0.3",
5
+ "version": "2.0.4",
6
6
  "icon": "icon.png",
7
7
  "author": "jianger666",
8
8
  "license": "MIT",