fix: report unknown tool arguments#2064
Conversation
|
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
OrKoN
left a comment
There was a problem hiding this comment.
per #1940 I do not think we want to silently swallow unknown parameters instead we want to improve the error message? cc @zyzyzyryxy
3041178 to
3172df2
Compare
|
Thanks, that makes sense. I updated the PR so unknown arguments are no longer silently ignored. The registered schema now lets the call reach the tool handler, but the handler returns an explicit error naming the unknown argument(s) and the expected arguments, then stops before invoking the tool.\n\nI also retitled the PR and amended the commit to reflect that behavior. Verified with:\n- |
zyzyzyryxy
left a comment
There was a problem hiding this comment.
Looks about right.
CLA still seem to be not resolved, so cannot approve just yet.
3172df2 to
edd845d
Compare
|
Thanks again. I applied both review suggestions and updated the PR description to match the current behavior. Verified again with:
The |
🤖 I have created a release *beep* *boop* --- ## [1.0.0](ChromeDevTools/chrome-devtools-mcp@chrome-devtools-mcp-v0.26.0...chrome-devtools-mcp-v1.0.0) (2026-05-18) ### 🎉 Features * report new URL after actions that trigger navigation ([ChromeDevTools#1853](ChromeDevTools#1853)) ([b594858](ChromeDevTools@b594858)) * support filePath in evaluate_script ([ChromeDevTools#2054](ChromeDevTools#2054)) ([90d368d](ChromeDevTools@90d368d)) ### 🛠️ Fixes * disable NetworkManager in DevTools ([ChromeDevTools#1834](ChromeDevTools#1834)) ([d0e6539](ChromeDevTools@d0e6539)) * do not use getSelectedMcpPage ([85f935b](ChromeDevTools@85f935b)) * improve geolocation emulation ([ChromeDevTools#2036](ChromeDevTools#2036)) ([213720b](ChromeDevTools@213720b)) * report unknown tool arguments ([ChromeDevTools#2064](ChromeDevTools#2064)) ([041b208](ChromeDevTools@041b208)) * respect user's npm registry configuration in update check ([ChromeDevTools#2038](ChromeDevTools#2038)) ([83a299f](ChromeDevTools@83a299f)) ### 📄 Documentation * explain concurrent session options ([ChromeDevTools#2062](ChromeDevTools#2062)) ([41944b3](ChromeDevTools@41944b3)) * fix typo ([ChromeDevTools#2075](ChromeDevTools#2075)) ([1deb4f8](ChromeDevTools@1deb4f8)) * remove windows workaround and document Node LTS support ([ChromeDevTools#2074](ChromeDevTools#2074)) ([30dcd0b](ChromeDevTools@30dcd0b)) * unhide various experimental flags ([ChromeDevTools#2055](ChromeDevTools#2055)) ([081c903](ChromeDevTools@081c903)) ### 🏗️ Refactor * waitForResult helpers ([ChromeDevTools#2041](ChromeDevTools#2041)) ([f6a12be](ChromeDevTools@f6a12be)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
🤖 I have created a release *beep* *boop* --- ## [1.0.0](chrome-devtools-mcp-v0.26.0...chrome-devtools-mcp-v1.0.0) (2026-05-18) ### 🎉 Features * report new URL after actions that trigger navigation ([#1853](#1853)) ([b594858](b594858)) * support filePath in evaluate_script ([#2054](#2054)) ([90d368d](90d368d)) ### 🛠️ Fixes * disable NetworkManager in DevTools ([#1834](#1834)) ([d0e6539](d0e6539)) * do not use getSelectedMcpPage ([85f935b](85f935b)) * improve geolocation emulation ([#2036](#2036)) ([213720b](213720b)) * report unknown tool arguments ([#2064](#2064)) ([041b208](041b208)) * respect user's npm registry configuration in update check ([#2038](#2038)) ([83a299f](83a299f)) ### 📄 Documentation * explain concurrent session options ([#2062](#2062)) ([41944b3](41944b3)) * fix typo ([#2075](#2075)) ([1deb4f8](1deb4f8)) * remove windows workaround and document Node LTS support ([#2074](#2074)) ([30dcd0b](30dcd0b)) * unhide various experimental flags ([#2055](#2055)) ([081c903](081c903)) ### 🏗️ Refactor * waitForResult helpers ([#2041](#2041)) ([f6a12be](f6a12be)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
Summary
Fixes #1940
Tests
npm run check-formatnpx tsc --noEmitOnError false(emits build artifacts but still reports the existingchrome-devtools-frontendtype conflict inModelImpl.ts)node --experimental-strip-types --no-warnings=ExperimentalWarning scripts/post-build.tsNODE_TEST_REPORTER=spec npm run test:no-build -- tests/ToolHandler.test.ts