tkrabel / bamboolib

bamboolib - a GUI for pandas DataFrames
https://bamboolib.com
939 stars 94 forks source link

Docker support might help #13

Closed neomatrix369 closed 4 years ago

neomatrix369 commented 4 years ago

Environment

Build recommended, please run jupyter lab build: bamboolib needs to be included in build plotlywidget needs to be included in build @8080labs/qgrid needs to be included in build @jupyter-widgets/jupyterlab-manager needs to be included in build jupyterlab-plotly changed from file:../extensions/jupyterlab-plotly-1.5.2.tgz to file:../extensions/jupyterlab-plotly-1.5.4.tgz

* If bamboolib is used with Jupyter Notebook: Notebook extension: `jupyter nbextension list`

### Description of Issue

I was installing `bamboolib` on my macOS and expected the installation to go smooth but it seems some other package might be conflicting after performing the last steps at [installation steps](https://github.com/tkrabel/bamboolib/blob/master/installation/no_virtual_environment/installation.md#22-jupyter-lab-10) - I got this error message:

[LabBuildApp] JupyterLab 1.2.7 [LabBuildApp] Building in /Users/swami/.local/share/jupyter/lab [LabBuildApp] Building jupyterlab assets (build:prod) [LabBuildApp] WARNING | The extension "nbdime-jupyterlab" is outdated.

An error occured. RuntimeError: JupyterLab failed to build See the log file for details: /var/folders/lv/qn495mln6h79dkh4b6j3rclm0000gn/T/jupyterlab-debug-1u0e_k9s.log


Looking into the logs shows me:

... [LabBuildApp] > node /Users/swami/.local/lib/python3.7/site-packages/jupyterlab/staging/yarn.js run build:prod [LabBuildApp] yarn run v1.15.2 $ ensure-max-old-space webpack --config webpack.prod.config.js ModuleNotFoundError: Module not found: Error: Can't resolve 'es6-promise/auto' in ... ...



As per the gitter discussions, it appears a version of plotly lab extension conflicts when trying to build the lab extensions, more details in the section below.

### Reproduction Steps

This one might be hard to reproduce as it's user specific, but hopefully, the attached log file might prove it:

[jupyterlab-debug-1u0e_k9s.log](https://github.com/tkrabel/bamboolib/files/4329059/jupyterlab-debug-1u0e_k9s.log)

Also this message on the `gitter` channel of `jupyterlabs`: https://gitter.im/jupyterlab/jupyterlab?at=5e4711fa46e99d431f78c53d (search for the messages around `ModuleNotFoundError: Module not found: Error: Can't resolve 'es6-promise/auto' in '/opt/conda/share/jupyter/lab/staging/build`

### What steps have you taken to resolve this already?

Building a docker image installed with bamboo and other notebooks extensions (as per the instructions) and run jupyter lab using this container.

### Anything else?

Happy to contribute the script(s) to the repo if there is interest
neomatrix369 commented 4 years ago

I'm basing my docker images on this https://github.com/8080labs/bamboolib_binder_template/blob/master/Dockerfile - and will add some more things to help the end user

tkrabel commented 4 years ago

The main issue seems so have been related to your setup, more specifically the JupyterLab extension nbdime-jupyterlab (see also #18). The best way to avoid such errors is to either create a new virtual environment (though conda, venv, or alike) or to use Docker.

Happy to start a discussion about how to provide better instructions & help on how to install bamboolib inside a new virtual environment or Docker :)

neomatrix369 commented 4 years ago

The main issue seems so have been related to your setup, more specifically the JupyterLab extension nbdime-jupyterlab (see also #18). The best way to avoid such errors is to either create a new virtual environment (though conda, venv, or alike) or to use Docker.

Happy to start a discussion about how to provide better instructions & help on how to install bamboolib inside a new virtual environment or Docker :)

The issues I faced with the license key not being saved isn't related to what you say.

Also, it's good to have support for isolate environment runtime i.e. via Docker or the likes. I have seen often the suggestions like install virtualenv, pip conda, anconda pip and the likes could lead to a lot of time and resources spent to get things to work. Some user is bound to have unexpected dependency conflicts or might just not want to manage another environment.

A docker-like solution is easy to kickstart and works consistently everywhere (more reliable say)

When I kicked off the docker solution in this PR, I was free from any of the other issues I reported.

The license key not getting saved is a different thing in hand.

neomatrix369 commented 4 years ago

I would say instead of instructions, please provide shell scripts or installation programs that get bamboolib running with a single or couple of steps (either Docker or shell scripts or binary installer).

This way everyone can run them exactly the same way in their environment and also contribute back (and it's version controlled) - unlike instructions which can be interpreted differently at times.

A good example is see https://bit.ly/better-nlp-launch, you have many ways to kick off the notebooks and get the library working, without having to install much or anything at all - consistently and reliably, given it need some fiddly dependencies to get to work correctly