deno
13138f65 - feat(ext/websocket): emit Network.* inspector events for WebSocket (#34222)

Commit
66 days ago
feat(ext/websocket): emit Network.* inspector events for WebSocket (#34222) Follow-up to #34220, on top of the same `internals.__inspectorNetwork` bridge. When the inspector is attached, constructing a `WebSocket` now emits `Network.webSocketCreated`, the resolved handshake response emits `Network.webSocketHandshakeResponseReceived` with real status/statusText/headers (`op_ws_create` returns them now), and every code path that dispatches the user-visible `CloseEvent` also emits `Network.webSocketClosed`. DevTools and `node:inspector` clients see WebSocket traffic alongside the fetch events. The compat test `parallel/test-inspector-network-websocket.js` is ignored with a reason: it asserts the initiator stack contains a frame matching `/undici/`, which is a Node-internal detail of how Node's WebSocket is built on undici. Deno's WebSocket is native, so no such frame exists; the rest of the assertions pass (verified with a standalone smoke test).
Author
Parents
Loading