Skip to main content

Module cdp

Module cdp 

Source
Expand description

A small Chrome DevTools Protocol client over a pipe: JSON messages each ended by a NUL byte (what --remote-debugging-pipe speaks). Calls are matched to their answers by id; events go to the session they belong to, each session with a queue of its own, so a screencast frame is never dropped (a frame that is not acknowledged stops the stream). docs/specs/SPEC_STREAMED_BROWSER_PANE_DEMO_2026_11_15.md §3.

Structs§

Cdp
Event
An event the browser sent.

Constants§

CALL_TIMEOUT 🔒
How long a call may wait for its answer.
MAX_MESSAGE 🔒
The longest message read from the browser (a screencast frame is the largest by far).

Functions§

encode
One message as it goes on the pipe.
split_messages
Split what has been read into whole messages, keeping the unfinished tail.

Type Aliases§

Deliver 🔒
Where a session’s events go: a function, so a pane can have the events of all its windows arrive on one queue, each tagged.
Pending 🔒
Sessions 🔒