[GH-ISSUE #4736] [Bug] VS Code rejects REA tool schema: mcp_rea_build_call_path #2469

Closed
opened 2026-10-17 21:05:12 +00:00 by bsakaguchi · 4 comments
Owner

Originally created by @Rai123817 on GitHub (Oct 17, 2026).
Original GitHub issue: https://github.com/morluto/rea/issues/4736

Before submitting

  • I searched the open and closed issues for a related report.
  • I removed credentials, tokens, private paths, and sensitive target data.

Area

Setup, packaging, or upgrade

Observed behavior

Title: VS Code rejects REA tool schema: mcp_rea_build_call_path

Environment

  • OS: Windows x64
  • VS Code: 1.142.0
  • REA package: rea-agents@6.5.0
  • Node.js: 24.20.0

Problem

After running npx rea-agents setup, selecting VS Code, and restarting VS Code, REA appears as running. However, every attempt to use REA tools in chat fails with:

Failed to validate tool mcp_rea_build_call_path: Error: tool parameters array type must have items. Please open an issue for the MCP server or extension which provides this tool

Diagnostics

  • npx -y rea-agents@6.5.0 capabilities runs successfully.
  • npx -y rea-agents@6.5.0 doctor --client vscode --json reports that the Node.js runtime, VS Code registration, and installed skill are aligned.
  • The diagnostic reports 207 MCP tools.
  • The live server identity remains unknown.

Expected behavior

VS Code should accept the advertised REA tool schemas and allow the tools to be called.

Question

Could you confirm whether mcp_rea_build_call_path advertises an invalid array schema or whether this is a VS Code compatibility issue? Please advise on a compatible version or fix.

Reproduction

  1. Installed rea-agents@6.5.0 using npx rea-agents setup.
  2. Selected VS Code as the client and approved the setup.
  3. Restarted VS Code.
  4. Confirmed that REA appears as running.
  5. Tried asking VS Code Chat to list REA tools.
  6. The same tool schema validation error appeared.

Expected behavior

VS Code should accept the REA MCP tool schemas and allow REA tools to be called successfully.

Impact and scope

On my Windows setup, REA's tools cannot be used through VS Code Chat because validation fails. The CLI capabilities command runs successfully. I have not tested other clients.

REA version

rea-agents@6.5.0

Runtime and platform

  • OS: Windows x64 - VS Code: 1.142.0 - Node.js: 24.20.0 - npm: 11.19.0

Target and artifact context

No target binary or artifact was opened. The error occurs when attempting to use REA tools in VS Code Chat.

Interface

MCP

Earliest failure stage

Request parsing or validation

Relevant output or evidence

Failed to validate tool mcp_rea_build_call_path: Error: tool parameters array type must have items. Please open an issue for the MCP server or extension which provides this tool.

The REA capabilities command runs successfully. The VS Code doctor diagnostic reports the VS Code registration as aligned and lists 207 MCP tools. The live server identity is reported as unknown.

Typed outcome or recovery expected

Please advise how to fix the schema validation error or identify a compatible REA/VS Code version so the tools can be used in VS Code Chat.

Analysis or suspected cause

The error suggests that the advertised schema for mcp_rea_build_call_path contains an array definition without the required items field, or that the schema is incompatible with the VS Code tool validator. This is a suspicion, not a confirmed root cause.

Additional context

The VS Code MCP registration and installed REA skill were reported as aligned by the doctor command. Optional analysis engines such as Ghidra, IDA, and JADX are not configured. I have not installed these optional engines because the current issue occurs before a tool call can run.

Originally created by @Rai123817 on GitHub (Oct 17, 2026). Original GitHub issue: https://github.com/morluto/rea/issues/4736 ### Before submitting - [x] I searched the open and closed issues for a related report. - [x] I removed credentials, tokens, private paths, and sensitive target data. ### Area Setup, packaging, or upgrade ### Observed behavior **Title:** VS Code rejects REA tool schema: `mcp_rea_build_call_path` **Environment** - OS: Windows x64 - VS Code: 1.142.0 - REA package: `rea-agents@6.5.0` - Node.js: `24.20.0` **Problem** After running `npx rea-agents setup`, selecting VS Code, and restarting VS Code, REA appears as running. However, every attempt to use REA tools in chat fails with: `Failed to validate tool mcp_rea_build_call_path: Error: tool parameters array type must have items. Please open an issue for the MCP server or extension which provides this tool` **Diagnostics** - `npx -y rea-agents@6.5.0 capabilities` runs successfully. - `npx -y rea-agents@6.5.0 doctor --client vscode --json` reports that the Node.js runtime, VS Code registration, and installed skill are aligned. - The diagnostic reports 207 MCP tools. - The live server identity remains `unknown`. **Expected behavior** VS Code should accept the advertised REA tool schemas and allow the tools to be called. **Question** Could you confirm whether `mcp_rea_build_call_path` advertises an invalid array schema or whether this is a VS Code compatibility issue? Please advise on a compatible version or fix. ### Reproduction 1. Installed `rea-agents@6.5.0` using `npx rea-agents setup`. 2. Selected VS Code as the client and approved the setup. 3. Restarted VS Code. 4. Confirmed that REA appears as running. 5. Tried asking VS Code Chat to list REA tools. 6. The same tool schema validation error appeared. ### Expected behavior VS Code should accept the REA MCP tool schemas and allow REA tools to be called successfully. ### Impact and scope On my Windows setup, REA's tools cannot be used through VS Code Chat because validation fails. The CLI capabilities command runs successfully. I have not tested other clients. ### REA version rea-agents@6.5.0 ### Runtime and platform - OS: Windows x64 - VS Code: 1.142.0 - Node.js: 24.20.0 - npm: 11.19.0 ### Target and artifact context No target binary or artifact was opened. The error occurs when attempting to use REA tools in VS Code Chat. ### Interface MCP ### Earliest failure stage Request parsing or validation ### Relevant output or evidence Failed to validate tool mcp_rea_build_call_path: Error: tool parameters array type must have items. Please open an issue for the MCP server or extension which provides this tool. The REA capabilities command runs successfully. The VS Code doctor diagnostic reports the VS Code registration as aligned and lists 207 MCP tools. The live server identity is reported as unknown. ### Typed outcome or recovery expected Please advise how to fix the schema validation error or identify a compatible REA/VS Code version so the tools can be used in VS Code Chat. ### Analysis or suspected cause The error suggests that the advertised schema for `mcp_rea_build_call_path` contains an array definition without the required `items` field, or that the schema is incompatible with the VS Code tool validator. This is a suspicion, not a confirmed root cause. ### Additional context The VS Code MCP registration and installed REA skill were reported as aligned by the doctor command. Optional analysis engines such as Ghidra, IDA, and JADX are not configured. I have not installed these optional engines because the current issue occurs before a tool call can run.
Author
Owner

@XinwangTao commented on GitHub (Oct 17, 2026):

This looks like a real schema bug rather than a VS Code quirk: VS Code's validator follows JSON Schema where type: "array" must include items, and the error points at mcp_rea_build_call_path specifically. capabilities/doctor passing makes sense — they don't schema-validate every tool. If that tool has a parameter typed as an array (or a tuple), deriving the schema from TS types can serialize it as {"type":"array"} with no items. Suggest pinning a concrete item type (or explicit items: {} for untyped arrays) and adding a release-time check that validates every advertised tool schema against JSON Schema draft-07 — that would catch this class of issue across all MCP clients, not just VS Code.

<!-- gh-comment-id:6232128388 --> @XinwangTao commented on GitHub (Oct 17, 2026): This looks like a real schema bug rather than a VS Code quirk: VS Code's validator follows JSON Schema where `type: "array"` must include `items`, and the error points at mcp_rea_build_call_path specifically. capabilities/doctor passing makes sense — they don't schema-validate every tool. If that tool has a parameter typed as an array (or a tuple), deriving the schema from TS types can serialize it as `{"type":"array"}` with no items. Suggest pinning a concrete item type (or explicit `items: {}` for untyped arrays) and adding a release-time check that validates every advertised tool schema against JSON Schema draft-07 — that would catch this class of issue across all MCP clients, not just VS Code.
Author
Owner

@kaoru0822-kitauji commented on GitHub (Oct 17, 2026):

Reproduced the cause against the published rea-agents@6.5.0 and confirmed it is fixed on main but not yet released.

6.5.0 (executed): I ran the packaged rea mcp server over stdio and listed tools with clientInfo Visual Studio Code (207 tools). build_call_path advertises functions[].relationship_coverage…limited_directions as closed tuples with prefixItems and no items, for example {"type":"array","prefixItems":[{"type":"string","const":"callers"}],"minItems":1,"maxItems":1}. VS Code Copilot's tool schema normalizer (extensions/copilot/src/extension/tools/common/toolSchemaNormalizer.ts) throws tool parameters array type must have items for any type: "array" node with a falsy items. 22 other tools carry the same tuple shape.

Current main 2092f90b7 (executed): the same scan finds no array without items in either the full or compact input profile. Tuples now carry items alongside prefixItems (204b9f3ac, fix(contracts): preserve array guidance across MCP schema profiles). That commit also adds a catalog-wide check of this exact VS Code rule (tests/fixtures/mcpClientSchemaConstraints.ts).

204b9f3ac is not in 6.5.0, so the fix will reach you in the next release. Until then a source build of main should work. I did not run VS Code itself.

<!-- gh-comment-id:6232502241 --> @kaoru0822-kitauji commented on GitHub (Oct 17, 2026): Reproduced the cause against the published `rea-agents@6.5.0` and confirmed it is fixed on main but not yet released. **6.5.0 (executed):** I ran the packaged `rea mcp` server over stdio and listed tools with clientInfo `Visual Studio Code` (207 tools). `build_call_path` advertises `functions[].relationship_coverage…limited_directions` as closed tuples with `prefixItems` and **no `items`**, for example `{"type":"array","prefixItems":[{"type":"string","const":"callers"}],"minItems":1,"maxItems":1}`. VS Code Copilot's tool schema normalizer (`extensions/copilot/src/extension/tools/common/toolSchemaNormalizer.ts`) throws `tool parameters array type must have items` for any `type: "array"` node with a falsy `items`. 22 other tools carry the same tuple shape. **Current main 2092f90b7 (executed):** the same scan finds no array without `items` in either the `full` or `compact` input profile. Tuples now carry `items` alongside `prefixItems` (204b9f3ac, `fix(contracts): preserve array guidance across MCP schema profiles`). That commit also adds a catalog-wide check of this exact VS Code rule (`tests/fixtures/mcpClientSchemaConstraints.ts`). 204b9f3ac is not in 6.5.0, so the fix will reach you in the next release. Until then a source build of main should work. I did not run VS Code itself.
Author
Owner

@morluto commented on GitHub (Oct 17, 2026):

Revalidated at main 19329e43b: 26 focused schema checks passed across toolSchemaValidity.test.ts and compactInputSchemaMcp.test.ts. The checks validate SDK-converted advertised input/output schemas and the client-required array-items rule, including full and compact input profiles. The fix commit 204b9f3ac is an ancestor of current main.

Closing as fixed in source. This does not claim the published 6.5.0 package changed or that VS Code itself was exercised; the release limitation in the earlier diagnosis still applies. No analysis provider or target was launched.

<!-- gh-comment-id:6242144879 --> @morluto commented on GitHub (Oct 17, 2026): Revalidated at main 19329e43b: 26 focused schema checks passed across toolSchemaValidity.test.ts and compactInputSchemaMcp.test.ts. The checks validate SDK-converted advertised input/output schemas and the client-required array-items rule, including full and compact input profiles. The fix commit 204b9f3ac is an ancestor of current main. Closing as fixed in source. This does not claim the published 6.5.0 package changed or that VS Code itself was exercised; the release limitation in the earlier diagnosis still applies. No analysis provider or target was launched.
Author
Owner

@XinwangTao commented on GitHub (Oct 18, 2026):

Thanks for the thorough verification — the tuple→prefixItems narrowing explains why only build_call_path failed under VS Code's validator while capabilities/doctor passed. Since 6.5.0 is what most users are on, a patch release (6.5.1) containing 204b9f3 would help, or at least a note in the release notes so users know to upgrade once it ships. Happy to test the released version when it's out.

<!-- gh-comment-id:6244106090 --> @XinwangTao commented on GitHub (Oct 18, 2026): Thanks for the thorough verification — the tuple→prefixItems narrowing explains why only build_call_path failed under VS Code's validator while capabilities/doctor passed. Since 6.5.0 is what most users are on, a patch release (6.5.1) containing 204b9f3 would help, or at least a note in the release notes so users know to upgrade once it ships. Happy to test the released version when it's out.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
morluto/rea#2469
No description provided.