RhodiumGroup / docker_images

Docker images for Rhodium's jupyterlab deployments
2 stars 2 forks source link

Install NBDime #132

Open delgadom opened 4 years ago

delgadom commented 4 years ago

Workflow

Summary

Installs the nbdime package & plugin for computing and viewing jupyter notebook diffs in an interactive widget.

delgadom commented 4 years ago

@bolliger32 this similar to what worked on the pyTC image?

bolliger32 commented 4 years ago

Yup! Only a couple minor differences. Instead of nbdime extensions --enable I called jupyter serverextensions enable --py nbdim --sys-prefix. I'm trying to remember why... I think sys-prefix was needed b/c of some weirdness about where I was calling it and permissions between root and jovyan users. And I think I just called serverextensions enable b/c the labextension was already installed as part of the conda package. But I think the nbdime extensions command should do the same thing.

delgadom commented 4 years ago

huh yeah - they say that the nbdime extensions --enable command is equivalent to the following (not sure which sys-prefix/user/system is actually called):

jupyter serverextension enable --py nbdime [--sys-prefix/--user/--system]

jupyter nbextension install --py nbdime [--sys-prefix/--user/--system]
jupyter nbextension enable --py nbdime [--sys-prefix/--user/--system]

jupyter labextension install nbdime-jupyterlab

@bolliger32 you think the last line isn't necessary? It seems to be building just fine - were you getting the errors on jupyterlab load?

bolliger32 commented 4 years ago

@delgadom Yeah I think the conda install does the labextension install itself. So I think it's not necessary but also doesn't hurt. So if it's building and runs properly, I think it's it's good!

bolliger32 commented 3 years ago

I noticed we also need to jump through a few more hoops to make the web tool use an accessible IP address by default. See latest commit and https://nbdime.readthedocs.io/en/latest/config.html and https://nbdime.readthedocs.io/en/latest/vcs.html#git-integration

bolliger32 commented 3 years ago

hmm i think we also might need to bump gitpython to make the nbdime config-git command work. Or we'd have to do some manual git config file adjustments