Skip to content
This repository has been archived by the owner on Aug 30, 2022. It is now read-only.

I install but 'Dashboard view' not available in the Notebook (4.1?) #152

Closed
aruizga7 opened this issue Dec 8, 2015 · 6 comments
Closed
Labels
Milestone

Comments

@aruizga7
Copy link

aruizga7 commented Dec 8, 2015

I installed pip install jupyter_dashboards and restarted and when I open the Notebook, I have the Deploy options in the File menu but I do not have the 'Dashboard view' in the View menu.

See here in the video the problem: http://recordit.co/br6CwoFc6I

How can I activate the dashboard view? Thanks

@parente
Copy link
Member

parente commented Dec 8, 2015

Thanks for the repo. Can you let me know what version of Jupyter Notebook you're running? It's in the help menu once you open a notebook.

@aruizga7
Copy link
Author

aruizga7 commented Dec 8, 2015

Hi, I am using the following: https://hub.docker.com/r/jupyter/notebook/
I am running 4.0

@parente
Copy link
Member

parente commented Dec 8, 2015

I believe that image is actually built from the jupyter/notebook master branch which means it's a dev image. (@minrk is that right? If so, we should figure out a way to indicate it's building from master.)

Looking at your video, I notice the toolbar looks like it does in the upcoming 4.1 release which we haven't tested against yet. That's probably the source of the bug. We'll need to update to be compatible with 4.1 UI.

In the meantime, can you try using one of the jupyter docker images that uses a stable notebook release, like https://hub.docker.com/r/jupyter/scipy-notebook or any of the others listed at https://github.com/jupyter/docker-stacks.

@parente parente changed the title I install but 'Dashboard view' not available in the Notebook I install but 'Dashboard view' not available in the Notebook (4.1?) Dec 8, 2015
@parente parente added the bug label Dec 8, 2015
@parente parente added this to the 0.2.1 milestone Dec 8, 2015
@aruizga7
Copy link
Author

aruizga7 commented Dec 8, 2015

Hi, I have the following docker:
https://github.com/jupyter/docker-stacks/tree/master/datascience-notebook

When I execute 'pip install jupyter_dashboards' and I get the following error:

dashboardsjupyter

Any idea? Thanks!

@parente
Copy link
Member

parente commented Dec 9, 2015

The docker stacks images create a profile for user jovyan. When you run as root, there's no profile and the install fails. It probably shouldn't fail, and I'll open a bug about that, but in either case, you'll want to run the pip command as jovyan.

More info here about how the docker image is configured: https://github.com/jupyter/docker-stacks/tree/master/datascience-notebook#notebook-options

@parente
Copy link
Member

parente commented Dec 9, 2015

@aruizga7 and I had an out-of-band chat. The one-liner to get things going without requiring a new Dockerfile

docker run -d -p 8888:8888 --user jovyan jupyter/datascience-notebook \
  bash -c "pip install jupyter_dashboards && jupyter notebook" 

Fun eh?

For posterity? Sure!

The dashboard extension currently includes a new tornado handler. The addition of this new handler requires a restart of the jupyter notebook server to take effect. When we're running in one of the docker stacks, this restart causes the container to shut down. If the container was started with --rm then, oh dear, it's gone. If not, then it can be docker started but with much grumbling.

The command above starts the container as the user jovyan. It starts a bash shell and runs the pip install as this user, guaranteeing the extension is installed into the jovyan user profile (not root, which is the default user of the docker stack image for su'ing purposes). After the pip install, the command runs the notebook server, bypassing the default start-notebook.sh script (which also exists only for suing purposes when a custom NB_UID is specified.)

Of course, this means every time such a container starts, pip is going to contact PyPI and do the install. The alternative is to write a new Dockerfile and build a new permanent docker image like so:

FROM jupyter/datascience-notebook
USER jovyan
RUN pip install jupyter_dashboards
USER root
docker build -t my/dashboard-notebook .
docker run -d -p 8888:8888 my/dashboard-notebook

I'm going to close out this item since the original problem is now addressed. I'll open a new one to test against 4.1. (Occurs to me our toolbar just might be hidden by default now, which is the new 4.1 behavior.)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants