Skip to content

feat: add support for DevTools Issues#3402

Merged
kblok merged 2 commits into
masterfrom
implement-upstream-change-14845
Apr 21, 2026
Merged

feat: add support for DevTools Issues#3402
kblok merged 2 commits into
masterfrom
implement-upstream-change-14845

Conversation

@kblok

@kblok kblok commented Apr 20, 2026

Copy link
Copy Markdown
Member

Summary

Implements changes from puppeteer/puppeteer#14845 which adds support for DevTools issue events.

  • Add Issue class with Code and Details properties representing a DevTools issue
  • Add IssueEventArgs event arguments class
  • Add IssuesEnabled option (default: true) to LaunchOptions, ConnectOptions, and IBrowserOptions to allow disabling issue monitoring
  • Add Issue event to IPage interface and Page abstract class
  • Add IsIssuesEnabled() to Browser base class, CdpBrowser, and BidiBrowser
  • Enable Audits.enable CDP command in FrameManager.InitializeAsync when issues are enabled
  • Handle Audits.issueAdded CDP events in FrameManager and emit Page.Issue events
  • Add CDP messaging types: AuditsIssueAddedResponse, AuditsInspectorIssue
  • Add tests for CSP violation issues and cross-origin iframe issue detection
  • Add BiDi skip entry for Issue tests in upstream test expectations (BiDi does not support issue events)

Test plan

  • ShouldEmitIssueEventWhenCspViolationOccurs - passes
  • ShouldEmitIssueEventFromCrossOriginIframe - passes
  • ShouldBeAbleToConnectAndDisableIssues - passes
  • All 3 tests pass with BROWSER=CHROME PROTOCOL=cdp

🤖 Generated with Claude Code

kblok and others added 2 commits April 20, 2026 13:16
Implements puppeteer/puppeteer#14845 which adds
support for DevTools issue events via the Audits CDP domain.

- Add `Issue` class and `IssueEventArgs` for DevTools issue data
- Add `IssuesEnabled` option to `LaunchOptions`, `ConnectOptions`, and `IBrowserOptions`
- Add `Issue` event to `IPage` interface and `Page` abstract class
- Add `IsIssuesEnabled()` to `Browser`, `CdpBrowser`, and `BidiBrowser`
- Enable `Audits.enable` in `FrameManager.initialize` when issues are enabled
- Handle `Audits.issueAdded` CDP events in `FrameManager`
- Add CDP messaging types: `AuditsIssueAddedResponse`, `AuditsInspectorIssue`
- Add tests for CSP violation issues and cross-origin iframe issues
- Skip Issue event tests for BiDi in upstream test expectations

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@kblok kblok merged commit 478991d into master Apr 21, 2026
24 of 26 checks passed
@kblok kblok deleted the implement-upstream-change-14845 branch April 21, 2026 13:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant