jupyterlab-dash
jupyterlab-dash copied to clipboard
dash on Jupyterlab running in docker
I'm running the python data science notebook docker image.
I tried enabling the dash extension from jupyterlab's extension manager, which did not work for me. I also tried following the instructions at: https://github.com/plotly/jupyterlab-dash#installation That also did not work.
Can someone please guide me on how to set it up in the environment I am using ?
The code I've run is:
!pip install jupyterlab_dash
!jupyter labextension install [email protected]
!jupyter labextension install jupyterlab-dash
# eveyrthing installs successfully
import jupyterlab_dash
import dash
import dash_html_components as html
viewer = jupyterlab_dash.AppViewer()
app = dash.Dash(__name__)
app.layout = html.Div('Hello World')
viewer.show(app)
Output:
Exception in thread Thread-105:
Traceback (most recent call last):
File "/opt/conda/lib/python3.7/threading.py", line 917, in _bootstrap_inner
self.run()
File "/opt/conda/lib/python3.7/threading.py", line 1166, in run
self.function(*self.args, **self.kwargs)
File "/opt/conda/lib/python3.7/site-packages/jupyterlab_dash/__init__.py", line 71, in _perform_show
""")
OSError:
Unable to communicate with the jupyterlab-dash JupyterLab extension.
Is this Python kernel running inside JupyterLab with the jupyterlab-dash
extension installed?
You can install the extension with:
$ jupyter labextension install jupyterlab-dash
I hit the same issue. Might relate to permission.
[W 02:42:12.618 NotebookApp] 500 POST /lab/api/build?1587004926480 (172.17.0.1): [Errno 1] Operation not permitted: '/opt/conda/share/jupyter/lab/staging/index.js'
[W 02:42:12.619 NotebookApp] [Errno 1] Operation not permitted: '/opt/conda/share/jupyter/lab/staging/index.js'
This is probably because of #37.
I had also this issue, and I fixed it by installing jupyterlab=1.0.0
(instead of 1.2.0
)