MCP Inspector 0.17.1: optional parameters can't be edited, list fields throw 'trim' error
In MCP Inspector 0.17.1, I can't type into optional tool parameters such as optional_field: str|None = None, and I can't uncheck the null checkbox. Optional list parameters like approval_groups: list[str]|None = None throw 'Cannot read properties of undefined (reading 'trim')' when left empty. Is there a workaround or fix?
Originally asked on GitHub: https://github.com/modelcontextprotocol/inspector/issues/868
5 answers
This bug was closed as completed, so it is presumed fixed in a later MCP Inspector release; the thread does not name the exact fixed version and contains no maintainer explanation. On 0.17.1, optional string fields render with an input box and a null checkbox, but the box cannot be typed into and the checkbox cannot be unchecked (tested on macOS 15.7.1 with Safari 26.0.1 and Chrome 140.0.7339.186). Optional list and dict fields fail differently when left empty: a list such as approval_groups: list[str]|None = None shows 'Cannot read properties of undefined (reading 'trim')', and a dict such as filter: dict|None = None shows an error too. The workarounds reported in the thread are: for dict fields, enter '{}' or 'null' instead of leaving the field empty, which resolves the error; for list fields, enter '[]', which removes the error for that field but causes the same 'trim' error to appear on subsequent list parameters. If you are still on 0.17.1, upgrading to a newer MCP Inspector release and retesting is the most likely fix; this is general advice because the thread does not state which version corrected the regression.
Did this work for you?What @celcof tried on GitHub (Worked)
For an optional dict field (filter: dict|None = None), entering '{}' or 'null' instead of leaving it empty resolved the error for that field.
Did this work for you?What a GitHub user tried on GitHub (Partly worked)
For an optional list field (approval_groups: list[str]|None = None), entering '[]' removed the 'trim' error for that field, but the same error then appeared on subsequent list parameters.
Source: https://github.com/modelcontextprotocol/inspector/issues/868 (opens external site)
Did this work for you?What a GitHub user tried on GitHub (Didn't work)
Tried to type a value into an optional str|None parameter in 0.17.1; the input box would not accept typing.
Source: https://github.com/modelcontextprotocol/inspector/issues/868 (opens external site)
Did this work for you?What a GitHub user tried on GitHub (Didn't work)
Tried to uncheck the null checkbox for an optional parameter; the checkbox could not be toggled.
Source: https://github.com/modelcontextprotocol/inspector/issues/868 (opens external site)
Did this work for you?
Related questions
- MCP Inspector 0.10.2 sends null for unset optional params (error -32602)?
- Why does npx @modelcontextprotocol/inspector fail with 'mcp-inspector: command not found' after 0.10.0?
- How do I increase MCP Inspector's 10-second request timeout?
- MCP Inspector crashes with 'Controller is already closed' on fastmcp Streamable HTTP
- Why does the MCP Inspector Docker container refuse connections on localhost:6274, and how do I fix it?