npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

transient-display-data

v0.4.4

Published

Extension to display transient_display_data in Jupyter Lab

Downloads

38

Readme

npm version Anaconda-Server Badge

transient-display-data for Jupyter Lab

This is a JupyterLab extension that allows JupyterLab to receive messages in a new transient_display_data type and display them in the console window of the associted notebook.

As summarized here, the transient display data messages are designed to send messages that are transient in nature and will not be displayed and saved with the notebooks. Such messages include but not limited to status or progress information for long calculations, and debug information. This message type is identical to display_data in content so you only need to use message type transient_display_data instead of display_data to mark the message as transient.

This new message type is currently under review. However, even before it is officially accepted, kernels can send messages of this type safely because all Jupyter clients ignore messages of unknown types, and JupyterLab with this extension will be able to display them. An an example, the SoS Kernel uses this message type to send progress information during the execution of the SoS workflows.

How to install

  • If you are using conda version of JupyterLab, you can install this extension with command
    conda install jupyterlab-transient-display-data -c conda-forge
  • Otherwise you can install the transient-display-data extension using command
    jupyter labextension install transient-display-data
    or go to the extension manager, search for transient-display-data, and install.

How to use transient_display_data

After you installed this extention, you can test it by

  1. Create a notebook with Python 3 kernel
  2. Right click and select New Console for Notebook to create a console window
  3. Right click on the console window and you select Show Transient Message.
  4. In the Python notebook, enter
kernel = get_ipython().kernel
kernel.send_response(kernel.iopub_socket,
                     'transient_display_data',
                     {
                         'data': {
                             'text/plain': 'I am transient'
                         }
                     }
                    );

and a message I am transient should be displayed in the console window.

  1. If you are interested in trying SoS Notebook, you can click this link to start a JupyterLab session on our live server. You can create a new notebook with SoS kernel, open a console window, and execute for example a trivial workflow
%run
[1]
[2]
[3]

You can see progress messages in the console window.