Repository navigation
Conversation
Puppeteer already subscribes to Audits.issueAdded, so enabling the DevTools frontend's own Audits domain adds a second consumer of the same stream. On a target with a large retained issue backlog that second subscription replays the whole backlog through IssuesManager on session setup, which logs "No handler registered for issue code PerformanceIssue" for every unsupported entry and delays unrelated page work. Stub Audits.invoke_enable on the agent prototype the same way the Network emulation commands are already stubbed, so the frontend never enables the redundant subscription. The repeated no-op command bodies are extracted into a single helper while adding the fourth one.
pull Bot
pushed a commit
to oogalieboogalie/chrome-devtools-mcp
that referenced
this pull request
Sep 8, 2026
🤖 I have created a release *beep* *boop* --- ## [1.9.0](ChromeDevTools/chrome-devtools-mcp@chrome-devtools-mcp-v1.8.0...chrome-devtools-mcp-v1.9.0) (2026-09-08) ### 🎉 Features * Add --allow-unrestricted-paths by default for CLI ([ChromeDevTools#2618](ChromeDevTools#2618)) ([2dc104c](ChromeDevTools@2dc104c)) * add Agent Plugins 1.0 package ([ChromeDevTools#2623](ChromeDevTools#2623)) ([05d9e55](ChromeDevTools@05d9e55)) * add an option to turn off js execution tools ([ChromeDevTools#2627](ChromeDevTools#2627)) ([a78566e](ChromeDevTools@a78566e)) * Add cookie-debugging skill and improve network/pages tool descriptions ([ChromeDevTools#2596](ChromeDevTools#2596)) ([6a67552](ChromeDevTools@6a67552)) * add screencast fps option ([ChromeDevTools#2312](ChromeDevTools#2312)) ([2e641d8](ChromeDevTools@2e641d8)) * extend --no-javascript-evaluation to cover navigations and initScripts ([ChromeDevTools#2638](ChromeDevTools#2638)) ([4993a0f](ChromeDevTools@4993a0f)) * option to disable source maps ([ChromeDevTools#2628](ChromeDevTools#2628)) ([4430a76](ChromeDevTools@4430a76)) * **performance:** set default trace buffer size to match DevTools (1.2gb) ([ChromeDevTools#2614](ChromeDevTools#2614)) ([d1baa90](ChromeDevTools@d1baa90)) * support configurable filesystem roots ([ChromeDevTools#2605](ChromeDevTools#2605)) ([d00e6f8](ChromeDevTools@d00e6f8)) ### 🛠️ Fixes * detect scheduled script navigations ([ChromeDevTools#2622](ChromeDevTools#2622)) ([1b2c0e5](ChromeDevTools@1b2c0e5)) * do not enable the DevTools frontend Audits subscription ([ChromeDevTools#2625](ChromeDevTools#2625)) ([d1e73ff](ChromeDevTools@d1e73ff)) * filter out Chrome webui targets by default ([ChromeDevTools#2648](ChromeDevTools#2648)) ([020c048](ChromeDevTools@020c048)) * honor background when new_page uses isolatedContext ([ChromeDevTools#2658](ChromeDevTools#2658)) ([f215c82](ChromeDevTools@f215c82)) * **memory:** expliclity mention the need of a flag ([ChromeDevTools#2620](ChromeDevTools#2620)) ([46c3e05](ChromeDevTools@46c3e05)) * truncate long urls in concise network request output ([ChromeDevTools#2513](ChromeDevTools#2513)) ([552c870](ChromeDevTools@552c870)) * validate viewport and geolocation inputs in emulate tool ([ChromeDevTools#2663](ChromeDevTools#2663)) ([808aed6](ChromeDevTools@808aed6)), closes [ChromeDevTools#2662](ChromeDevTools#2662) ### 📄 Documentation * correct what --screenshotFormat reduces ([ChromeDevTools#2617](ChromeDevTools#2617)) ([c575777](ChromeDevTools@c575777)) * split the docs in separate files ([ChromeDevTools#2600](ChromeDevTools#2600)) ([5463101](ChromeDevTools@5463101)) * update agents.md for testing ([ChromeDevTools#2660](ChromeDevTools#2660)) ([18ca912](ChromeDevTools@18ca912)) * update SECURITY.md ([ChromeDevTools#2626](ChromeDevTools#2626)) ([fd67970](ChromeDevTools@fd67970)) ### 🏗️ Refactor * extract browser options ([ChromeDevTools#2654](ChromeDevTools#2654)) ([a918b7b](ChromeDevTools@a918b7b)) * extract category config into a seprate file ([ChromeDevTools#2652](ChromeDevTools#2652)) ([401a119](ChromeDevTools@401a119)) * move transform logic to Clearcut level ([ChromeDevTools#2637](ChromeDevTools#2637)) ([f0058d5](ChromeDevTools@f0058d5)) * wrap Server into a class ([ChromeDevTools#2633](ChromeDevTools#2633)) ([1a092ff](ChromeDevTools@1a092ff)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Puppeteer already subscribes to
Audits.issueAdded.overrideDevToolsGlobalsdid not stop the DevTools frontend from enabling its ownAuditsdomain, so a second consumer of the same stream was created on session setup. Against a target holding a large retained issue backlog, that second subscription replays the entire backlog throughIssuesManager, loggingNo handler registered for issue code PerformanceIssueper unsupported entry and delaying unrelated page work.This stubs
Audits.invoke_enableon the agent prototype exactly the way the Network emulation commands are already stubbed, so the redundant subscription is never enabled. The four identical no-op command bodies are collapsed into onenoopAgentCommandhelper while adding the fourth.Why this matters
Closes #2556
The guard added in #2535 covers
PageEventSubscriber.#onIssueAdded, the collector's own subscription. It does not cover the frontend'sIssuesManagerpath, which is the other consumer of the same CDP event, so the warning and the backlog replay both survive it. Fixing it at theinvoke_enableboundary means the frontend never receives the replay at all, rather than filtering each issue after the fact.Testing
node scripts/test.js tests/devtools/DevtoolsUtils.test.ts-> 20 passing.npm run buildandnpm run typecheckboth clean.The added case builds a real 500-issue
PerformanceIssuebacklog on a page, detaches, then constructs the target universe and asserts the warning is never emitted whileRuntime.evaluatestill works.It pins the defect rather than just covering the path. Reverting only
src/devtools/DevtoolsUtils.ts, rebuilding, and re-running:Not tested: no measurement of the tool-call timeout the report describes on a long-lived session. The test asserts the backlog is no longer replayed, which is the mechanism, not the end-to-end latency.
AI was used for assistance.