inspector/core/json
Repository files (latest commit first)
Filename Latest commit message Latest commit date
cliffhall 9516299d8d fix(web): refuse a raw-JSON tool argument the schema would retype (#2171)
The Tools and Apps tabs' "Edit as JSON" editor sent its draft through the
string-to-declared-type conversion `callTool` applies for the widget form, so
`{"count":"01"}` against a numeric schema left as `{"count":1}` — the editor
showed one payload and the wire carried another.

Both JSON-authoring surfaces now refuse such a draft and name the value to
rewrite. Edit-and-replay already did; this makes the Tools and Apps forms
agree with it, which is the consistency #2171's acceptance asks for.

`coercedArgumentNames` and `coercedArgumentsError` move into core/json so the
two surfaces share one predicate and one sentence — the check runs the real
conversion and compares rather than restating its rules, so it cannot drift
from what would actually be sent. Enforcement is opt-in
(`SchemaFormProps.enforceToolArgumentTypes`): an elicitation renders through
the same form and its values are never converted, so enforcing there would
refuse a draft for a reason that is not true of it.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0177mPHAdECD18nLLCTwR5rh
Signed-off-by: cliffhall <cliff@futurescale.com>
2026-08-27 22:57:29 -04:00
..
jsonUtils.ts fix(web): refuse a raw-JSON tool argument the schema would retype (#2171) 2026-08-27 22:57:29 -04:00
nullableUnion.ts fix: address Copilot review round 32 — normalize before the type vote, enum-spelled null 2026-08-26 12:50:20 -04:00
rootUnion.ts fix: address Copilot review round 41 — const does not demand a property, required-only branches 2026-08-26 16:08:24 -04:00
schemaLint.ts fix: stop claiming a bare-true replacement narrows the contract 2026-08-25 03:41:17 -04:00
xMcpHeader.ts fix(core): mirror SEP-2243 x-mcp-header args to Mcp-Param-* on tools/call (#1847) 2026-07-28 19:19:48 -04:00