Is it possible to get advanced debug level output on a jupyter notebook run? I’m running a ipynb file from SpyCloud which generates its own GUI via widgets, but the notebook is failing to execute/run properly in JupyterHub and is instead just looking like it’s executed every line without error but widgets don’t display, and the web browser (Firefox) shows this in the console logs:
Failed to fetch ipywidgets through the “jupyter.widget.control” comm channel, fallback to fetching individual model state. Reason: Control comm was closed too early
… and this is the only reason I can think of which would cause widgets to fail.
I guess I have the same question about jupyterlab that we start via jupyterhub. In the journal I can only find output from jupyterhub, but not from the jupyterlabs that are started for the users.
In our case we had the problem that a python kernel was just not starting and we couldn’t figure out why because there was no log output anywhere.
What we finally did was starting the jupyterlab manually from the juypyterhub installation by /opt/jhub/bin/jupyter lab --debug --no-browser and then connect to it via the browser. I.e., we start the same jupyterlab as jupyterhub would do it. That might help you also perhaps…
But the question remains:
a) where does jupyterhub pipe the output from the notebooks/labs to and
b) is it possible to pass parameters to notebook/lab to add the --debug parameter?
It depends on your JupyterHub configuration, in particular which spawner you’ve configured. For example, the default spawner will result in the singleuser logs going to the same place as the main hub process, whereas if you’re using DockerSpawner or KubeSpawner the logs are handled by your container runtime.
It was both, but this helped figure out the debugging part which didn’t yield anything. So that part is answered. As for the widgets now, well, I’ve opened up a separate thread for that one now as that’s the remaining issue.