Announcing Dash Bio 1.0.0 🎉 : a one-stop-shop for bioinformatics and drug development visualizations.

Jupyterlab-plotly not compatible with jupyterlab 3.0

I was trying to update my jupyterlab to the 3.0 version, but after the update, my plotly extension stop working. Here are the error message:

(base) tenggao@TENGMGAO-MB0 python_misc % jupyter labextension install jupyterlab-plotly@4.14.1
An error occured.
ValueError: 
"jupyterlab-plotly@4.14.1" is not compatible with the current JupyterLab
Conflicting Dependencies:
JupyterLab                        Extension      Package
>=3.0.0 <3.1.0                    >=1.3.0 <2.0.0||>=2.0.0 <3.0.0@jupyterlab/rendermime-interfaces
See the log file for details:  /var/folders/8l/gnphlfyj3yv77dh4wmzlvdfc0000gn/T/jupyterlab-debug-tt6h7brh.log

Are there a new version of the plotly extensions that can work with jupyterlab3.0?
Thanks in advance!

Not yet, we’re working on it :slight_smile:

Hi @nicolaskruchten!

I’ve just upgraded my JupyterLab v2.x + Plotly v4.x to JupyterLab v3.0.5 + Plotly v4.14.3, with all dependencies updated, and I’m getting blank spot with fig.show() (pio.renderers is showing “plotly_mimetype+notebook” as default renderer) while it works fine with Jupyter Notebook (pio.renderers also showing “plotly_mimetype+notebook” as default renderer).

Of course I also updated the lab extensions and rebuilded them.

plotly.__version__ and all Plotly lab extensions are returning v4.14.3.

Is this yet to be fixed or it should be fixed in this version?

I’m running Python 3.8.6 on Windows 10.

Thanks!

In principle things should work with JupyterLab 3.0 and the 4.14.3 extension. A couple of additional troubleshooting steps you might want to try:

  • in your Lab notebook, in the Kernel menu, choose “restart and clear outputs” and then save and close your notebook, then open it again and rerun it
  • are you launching JupyterLab yourself locally? If so, it’s important to ensure that you’re launching it from the same environment where you installed the lab extensions. Are you able to see the Plotly extensions in the JupyterLab UI via the extensions manager, and are they up to date there?

If nothing is working at all, it would be helpful if you could open up the browser developer tools and paste a screenshot of your Javascript console, so we can see if there are any useful error messages.

My Juypyterlab 3.0.5 issue may be related. The console error is when I try to render a plotly express example is about missing require.

Thanks

@TheAustinator Thanks for sharing a simple and effective solution. Below, I have copied the steps for easy implementation using your comment (applied for my case, Jupyterlab version 3.2.1
RESULTS:
JupyterLab v3.2.1
labextensions
@jupyter-widgets/jupyterlab-manager v3.0.0 enabled ok (python, jupyterlab_widgets)

Other labextensions (built into JupyterLab)
app dir:
jupyter-matplotlib v0.10.2 enabled ok
jupyterlab-dash v0.4.0 enabled ok
jupyterlab-plotly v5.4.0 enabled ok
plotlywidget v4.14.3 enabled ok

ACTIONS TO BE TAKEN
$ jupyter lab clean --all
$ jupyter labextension list
$ jupyter labextension install plotlywidget
$ jupyter labextension install jupyterlab-plotly
$ jupyter labextension install jupyterlab-dash
$ jupyter labextension install jupyter-matplotlib