JupyterLab 3 troubleshooting
Troubleshooting for JupyterLab 3 & 4
File save error
In rare occasions, one of the many database files used internally by JupyterLab can get corrupted, preventing the save of any changes to documents. You might see something like this on the UI:

If you encounter this, try the following steps:
Open new terminal window, and execute
jupyter lab path. You'll see something likeApplication directory: /opt/conda/share/jupyter/labTake the directory path, and issue the following command
rm <app_dir_path>/../nbsignatures.dbexample:rm /opt/conda/share/jupyter/lab/../nbsignatures.dbRestart the application
JupyterLab freezes when opening a specific file
Corrupted files can cause crashes in JupyterLab when opened for viewing. This can create a vicious circle:
You open the file, and the entire UI freezes
You restart the application, but JupyterLab tries to open the same file again upon loading, and the UI freezes again
To solve the issue, rename the problematic file in the Nuvolos File navigator and restart the application. As JupyterLab won't be able to find the file anymore, the UI will not freeze.
Running a Flask application and serving it to JupyterLab
You are able to run a Flask webserver application and make it visible in JupyterLab.
Components you need:
Install
nodejsfrom condanodejsis needed for commands such asjupyter labextension installandjupyter lab build. You might need to install a specific version ofnodejsdepending on the JupyterLab version. Currently version>=12.0.0is required.
Install the jupyter-server-proxy extension.
Flask version
>= 2.2.0is suggested.
Potential further useful tools:
We suggest also looking at the
jupyterlab_iframeextension.
Modify your flask application code
Make sure you add the following snippet to your flask application code:
from werkzeug.middleware.proxy_fix import ProxyFix
from werkzeug.middleware.dispatcher import DispatcherMiddleware
from werkzeug.wrappers import Response
# ...
# your code goes here
# ...
app.wsgi_app = DispatcherMiddleware(
Response('Not Found', status=404),
{'/proxy/absolute/5000': ProxyFix(app.wsgi_app)})Last updated
Was this helpful?