def send_spyder_msg(self, spyder_msg_type, content=None, data=None):
        """
        Publish custom messages to the Spyder frontend.

        Parameters
        ----------

        spyder_msg_type: str
            The spyder message type
        content: dict
            The (JSONable) content of the message
        data: any
            Any object that is serializable by cloudpickle (should be most
            things). Will arrive as cloudpickled bytes in `.buffers[0]`.
        """
        import cloudpickle

        if content is None:
            content = {}
        content['spyder_msg_type'] = spyder_msg_type
        msg = self.session.send(
            self.iopub_socket,
            'spyder_msg',
            content=content,
            buffers=[cloudpickle.dumps(data, protocol=PICKLE_PROTOCOL)],
            parent=self._parent_header,
        )
        self.log.debug(msg)
def send_spyder_msg ( self , spyder_msg_type , content = None , data = None ) : import cloudpickle if content is None : content = { } content [ 'spyder_msg_type' ] = spyder_msg_type msg = self . session . send ( self . iopub_socket , 'spyder_msg' , content = content , buffers = [ cloudpickle . dumps ( data , protocol = PICKLE_PROTOCOL ) ] , parent = self . _parent_header , ) self . log . debug ( msg )
Publish custom messages to the Spyder frontend.

        Parameters
        ----------

        spyder_msg_type: str
            The spyder message type
        content: dict
            The (JSONable) content of the message
        data: any
            Any object that is serializable by cloudpickle (should be most
            things). Will arrive as cloudpickled bytes in `.buffers[0]`.