tarasko / picows

Ultra-fast websocket client and server for asyncio
MIT License
136 stars 8 forks source link

message type of send_ping method. #17

Closed MrHat365 closed 1 month ago

MrHat365 commented 1 month ago

`cpdef send_ping(self, message=None): """ Send a PING control frame with an optional message.

    :param message: an optional bytes-like object
    """
    self.send(WSMsgType.PING, message)

` Sometimes when sending a ping frame, it needs to be a str or dict or json.

In fact, you can use the send() method instead, but this will reduce statistical efficiency.

Is it possible to increase the message type of ping to achieve more functions at once?