-
-
Notifications
You must be signed in to change notification settings - Fork 549
Description
In Jupyter Lab (version 4.0.9), I tried to use panel notifications, like:
import panel as pn
pn.extension(notifications=True)
pn.state.notifications.error('test')
The strange thing was that on the first time, the notification did not appear, but every time afterwards, the notification did appear. I produced this issue using the official docker image (quay.io/jupyter/minimal-notebook) and installed panel (1.3.6) via pip.
I eventually found the issue by debugging cell execution twice. During the first execution of pn.extension() and the second execution I found a difference: It appeared that panel_extension._display_globals in panel.config is not called the first time but only the second time. I presume this should not be the case?
To verify, I added panel_extension._display_globals()
manually after loading the extension, which resolved the issue
For completion, here is also some system context:
IPython : 8.18.1
ipykernel : 6.26.0
ipywidgets : not installed
jupyter_client : 8.6.0
jupyter_core : 5.5.0
jupyter_server : 2.12.1
jupyterlab : 4.0.9
nbclient : 0.8.0
nbconvert : 7.12.0
nbformat : 5.9.2
notebook : 7.0.6
qtconsole : not installed
traitlets : 5.14.0