Skip to content

Commit

Permalink
Doc: make it clear pyviz_comms need to be installed next to Jupyter (
Browse files Browse the repository at this point in the history
…#5980)

* make it clear pyviz_comms need to be installed next to Jupyter

* clearer env install instructions
  • Loading branch information
maximlt committed Dec 5, 2023
1 parent 0e2c6b1 commit 808bfc1
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
4 changes: 4 additions & 0 deletions doc/getting_started/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@ pip install panel

::::

:::{important}
Is Panel installed together with JupyterLab/Jupyter Notebook in your working environment? If not, you need to make sure that `pyviz_comms` is explicitly installed in the same environment as JupyterLab/Jupyter Notebook (`conda install pyviz_comms` or `pip install pyviz-comms`) for bi-directional communication to be fully working.
:::

:::{seealso}
If you intend to work with Panel in a non-Jupyter notebook environment such as VSCode have a quick at the [relevant how-to section](../how_to/notebook/other_nb.md).
:::
Expand Down
9 changes: 9 additions & 0 deletions doc/how_to/notebook/notebook.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,15 @@ This guide addresses how to display output in Jupyter and non-Jupyter based note

Once you have installed Panel it should automatically set up class Jupyter notebook and JupyterLab extensions for rendering Panel output and configuring communication channels to ensure the rendered output syncs bi-directionally with the Python process.

## Run Panel in another notebook kernel

You generally have two ways to install JupyterLab/Jupyter Notebook:

1. directly in your working environment that contains all the dependencies you need to run your project
2. in another environment, maybe a central environment or an environment dedicated to Jupyter, in which case when you run a notebook you should pick the kernel of your project environment

When in the second setup, you need to ensure that `pyviz_comms` is explicitly installed in the same environment as JupyterLab/Jupyter Notebook (with `conda install pyviz_comms` or `pip install pyviz-comms`) for bi-directional communication to be fully working.

## Loading the extension

The first step when working in a notebook environment should always be to load the `panel.extension`:
Expand Down

0 comments on commit 808bfc1

Please sign in to comment.