Beispiel #1
0
def publish_data(data):
    """publish a data_message on the IOPub channel

    Parameters
    ----------

    data : dict
        The data to be published. Think of it as a namespace.
    """
    from ipykernel.zmqshell import ZMQInteractiveShell
    ZMQInteractiveShell.instance().data_pub.publish_data(data)
Beispiel #2
0
def publish_data(data):
    """publish a data_message on the IOPub channel

    Parameters
    ----------

    data : dict
        The data to be published. Think of it as a namespace.
    """
    warnings.warn("ipykernel.datapub is deprecated. It has moved to ipyparallel.datapub", DeprecationWarning)
    
    from ipykernel.zmqshell import ZMQInteractiveShell
    ZMQInteractiveShell.instance().data_pub.publish_data(data)
def publish_data(data):
    """publish a data_message on the IOPub channel

    Parameters
    ----------
    data : dict
        The data to be published. Think of it as a namespace.
    """
    warnings.warn(
        "ipykernel.datapub is deprecated. It has moved to ipyparallel.datapub",
        DeprecationWarning,
        stacklevel=2)

    from ipykernel.zmqshell import ZMQInteractiveShell
    ZMQInteractiveShell.instance().data_pub.publish_data(data)
Beispiel #4
0
 def instance(self, *args, **kwargs):
     shell = ZMQInteractiveShell(*args, **kwargs)
     return shell