Skip to content

fix: resolve PermissionBlock CDP unmarshal errors#137

Closed
NewdlDewdl wants to merge 1 commit intoUTDNebula:developfrom
NewdlDewdl:fix/issue-131-cdproto-permissionblock
Closed

fix: resolve PermissionBlock CDP unmarshal errors#137
NewdlDewdl wants to merge 1 commit intoUTDNebula:developfrom
NewdlDewdl:fix/issue-131-cdproto-permissionblock

Conversation

@NewdlDewdl
Copy link
Contributor

@NewdlDewdl NewdlDewdl commented Mar 4, 2026

Fixes #131.

Root cause: Chrome now emits newer PrivateNetworkRequestPolicy values (PermissionBlock / PermissionWarn), and the pinned CDP dependency was too old to decode them. That led to repeated unmarshal errors during ChromeDP scraping.

Changes in this PR:

  • bumped github.com/chromedp/cdproto to v0.0.0-20250803210736-d308e07a266d
  • bumped github.com/chromedp/chromedp to v0.14.2 for compatibility with the updated protocol package
  • added regression test utils/chromedp_protocol_test.go to verify enum unmarshal for old + new policy values

Verification run:

  • go build ./...
  • go test ./parser ./uploader
  • go test ./utils -run TestPrivateNetworkRequestPolicyUnmarshal

All pass locally.

Note: full go test ./... still depends on local .env secrets for existing credentialed tests in utils.

@NewdlDewdl
Copy link
Contributor Author

@mikehquan19 pushed the dependency fix plus regression coverage.

Verification run locally:

  • go build ./...
  • go test ./parser ./uploader
  • go test ./utils -run TestPrivateNetworkRequestPolicyUnmarshal

@mikehquan19
Copy link
Contributor

Won't approve this one since it's AI-generated

@mikehquan19 mikehquan19 closed this Mar 4, 2026
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.

Fix the issue: ERROR: could not unmarshal event: unknown PrivateNetworkRequestPolicy value: PermissionBlock

2 participants