You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit ed8098c
Browse filesBrowse the repository at this point in the historyBrowse files
[Capability] Keep a nullable or union key of an array shape inside the shape (#613)
* [Capability] Keep a nullable or union key of an array shape inside the shape
* [Capability] Map unions inside array shape keys and generics recursively
---------
Co-authored-by: Christopher Hertel <mail@christopher-hertel.de>
Copy file name to clipboardExpand all lines: CHANGELOG.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,6 +8,8 @@ All notable changes to `mcp/sdk` will be documented in this file.
8
8
### Server
9
9
10
10
*[BC Break]`DocBlockParser::parseDocBlock()` no longer accepts `null`; pass `ReflectionMethod::getDocComment()` as is
11
+
* Fix tools with an array shape parameter whose keys are nullable or unions (e.g. `array{name: string, nickname: string|null}`) rejecting valid arguments with `-32602`: a `null` inside the shape no longer turns the parameter into `array|null`, and such keys get their own types instead of `object`, including lists and nested shapes (`string[]|null`, `array{x: int}|null`).
12
+
* Fix `array<string|null>` and other generics with a union element getting `items` of type `object`. A `null` inside a generic no longer makes the parameter nullable, and neither does a DocBlock class whose name contains `null`.
0 commit comments