def __init__(self, payload=None):
        """

        :param payload: The WebSocket ping message payload.
        :type payload: bytes or None
        """
        assert(payload is None or type(payload) == bytes), \
            ("invalid type {} for WebSocket ping payload - must be None or bytes".format(type(payload)))
        if payload is not None:
            assert(len(payload) < 126), \
                ("WebSocket ping payload too long ({} bytes) - must be <= 125 bytes".format(len(payload)))

        self.payload = payload
dataset/ETHPy150Open crossbario/autobahn-python/autobahn/websocket/types.py/Ping.__init__/original