Skip to content
This repository was archived by the owner on Aug 3, 2026. It is now read-only.

For testing nullable arrays in tool inputSchemas - #23

Closed
cliffhall wants to merge 2 commits into
olaservo:mainfrom
cliffhall:nullable-array-in-inputSchema
Closed

cliffhall wants to merge 2 commits into
olaservo:mainfrom
cliffhall:nullable-array-in-inputSchema

Conversation

@cliffhall

@cliffhall cliffhall commented Oct 29, 2025 •

Copy link
Copy Markdown
Contributor
  • In tools.ts
    • modified EchoSchema
      • made message field nullable with default null (just for testing nullable in a TextArea
      • added numberList field which is a nullable array with default of null
    • in ECHO tool handler,
      • added numberList contents to string that's echoed back

See modelcontextprotocol/inspector#846

Screenshot 2025-10-29 at 2 20 24 PM

…tocol/inspector#846

* In tools.ts
  - modified EchoSchema
    - made message field nullable with default null (just for testing nullable in a TextArea
    - added numberList field which is a nullable array with default of null
  - in ECHO tool handler,
    - added numberList contents to string that's echoed back
@cliffhall cliffhall changed the title For testing nullable arrays in tool inputSchemas. See https://github.… For testing nullable arrays in tool inputSchemas Oct 29, 2025
  - modified EchoSchema
    - removed message field nullable with default null, it was just for testing nullable in a TextArea, not needed for testing the nullable array PR.
@olaservo

olaservo commented Mar 9, 2026

Copy link
Copy Markdown
Owner

Hi @cliffhall — apologies for missing this contribution! We recently refactored the server from the low-level Server API to the new McpServer API with a modular file structure, which made this PR unmergeable as-is.

We've ported your nullable array test case into the latest main in commit e506da5 — the numberList field is now part of the echo tool in the new structure. Thank you for the contribution, and sorry for the delay!

@olaservo olaservo closed this Mar 9, 2026
olaservo added a commit that referenced this pull request Mar 9, 2026
…cture

Add nullable array, $ref resolution, and anyOf/enum test cases for
Inspector schema handling, adapted from PRs against the old monolithic
handlers/tools.ts to the new modular tool files.

Co-Authored-By: Cliff Hall <[email protected]>
Co-Authored-By: Claude Opus 4.6 <[email protected]>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants