zames_pro 2.82.122 → 2.82.123

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
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [2.82.123] - 2026-10-24
11
+
12
+ ### Fixed
13
+
14
+ - **mcp:** a duplicate tool rename does not steal a later tool name
15
+
10
16
  ## [2.82.122] - 2026-10-24
11
17
 
12
18
  ### Fixed
package/dist/mcp.js CHANGED
@@ -337,6 +337,11 @@ export function qualifyToolName(server, tool) {
337
337
  // qualifier is not injective (see the call site), hence this guard. Pure;
338
338
  // exported for tests.
339
339
  export function dedupeToolNames(tools) {
340
+ // The rename must avoid EVERY name in the list, not only the ones already
341
+ // visited: a later tool that already owns `<name>_2` (a server's own `x_2`
342
+ // tool) was renamed itself, and the model's call to `x_2` then reached the
343
+ // RENAMED DUPLICATE — the wrong tool.
344
+ const all = new Set(tools.map((t) => t.name));
340
345
  const seen = new Set();
341
346
  for (const t of tools) {
342
347
  if (!seen.has(t.name)) {
@@ -345,12 +350,16 @@ export function dedupeToolNames(tools) {
345
350
  }
346
351
  let n = 2;
347
352
  let candidate = `${t.name}_${n}`;
348
- while (seen.has(candidate)) {
353
+ while (seen.has(candidate) || all.has(candidate)) {
349
354
  n++;
350
355
  candidate = `${t.name}_${n}`;
351
356
  }
357
+ // The duplicate leaves the pool of ORIGINAL names: its old name belongs to
358
+ // the first tool of that name.
359
+ all.delete(t.name);
352
360
  t.name = candidate;
353
361
  seen.add(candidate);
362
+ all.add(candidate);
354
363
  }
355
364
  }
356
365
  // Connect to ONE server and return a ready connection (or an error).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zames_pro",
3
- "version": "2.82.122",
3
+ "version": "2.82.123",
4
4
  "description": "Terminal coding agent that drives a real browser to chat with DeepSeek, Qwen and other web LLMs — no API key required. Reads and edits files, runs commands, commits to git, like Claude Code / Codex CLI.",
5
5
  "type": "module",
6
6
  "bin": {