MCPcopy Index your code
hub / github.com/microsoft/playwright-python / once_web_socket_connection

Method once_web_socket_connection

tests/server.py:280–283  ·  view source on GitHub ↗
(
        self, handler: Callable[["WebSocketProtocol"], None]
    )

Source from the content-addressed store, hash-verified

278 self.once_web_socket_connection(lambda ws: ws.sendMessage(data))
279
280 def once_web_socket_connection(
281 self, handler: Callable[["WebSocketProtocol"], None]
282 ) -> None:
283 self._ws_handlers.append(handler)
284
285
286class HTTPServer(Server):

Calls 1

appendMethod · 0.80