Conversation
|
Firetiger deploy monitoring skipped This PR didn't match the auto-monitor filter configured on your GitHub connection:
Reason: PR title and empty body suggest planning discussion rather than actual code changes to kernel API endpoints or Temporal workflows; please add deploy monitoring manually if this involves kernel API modifications. To monitor this PR anyway, reply with |
|
|
||
| **Tests:** | ||
|
|
||
| - `cdp_proto_test.go` (NEW) — golden-fixture tests. For each Layer-1 struct, a captured real Chrome-emitted JSON frame in `testdata/`. Test decodes the frame, then re-marshals and asserts the round-trip preserves all top-level keys (catches dropped fields). This is the mechanical audit. |
There was a problem hiding this comment.
i think you want to compare normalized full JSON after decode/re-marshal and not just top level keys, to get a full structurual round trip check
you could also consider some light codegen around the json schema in json/js_protocol.json in the devtools repo
Note
Low Risk
Documentation-only change that proposes a future refactor; it does not modify runtime behavior or data handling in this PR.
Overview
Adds
plans/cdp-decode.md, a design plan to refactorcdpmonitorinto a two-layer CDP decode: protocol-faithful Layer-1 structs (retaining all PDL fields, with complex sub-objects asjson.RawMessage) and a Layer-2 projection that maps typed inputs to monitor events.The doc also outlines intended file/module changes and a proposed golden round-trip test strategy to ensure decoded JSON frames preserve all fields for handled CDP events.
Reviewed by Cursor Bugbot for commit 2d6311b. Bugbot is set up for automated code reviews on this repo. Configure here.