Issues Related to Support for JupyterLab 4.0 and Python 3.12


This article was written for Posit Workbench 2023.12.0 and below and may not apply to future versions of Workbench as we expect these issues to be resolved in a future release. Please see the Release Notes for your version of Workbench for more details. 


The release of JupyerLab 4.0.x has many major changes from previous versions. Therefore, it will take some time for JupyterLab 4.0.x to be supported in Posit Workbench. As of 2023.12.0, the highest supported version of JupyterLab is 3.6.6. 


Users encountering this issue may see errors such as the below if they are trying to install an incompatible version of JupyterLab or Python. Exact version numbers and packages reported in the error may vary.

When trying to use Python 3.12 and above with Jupyter 3.x:

Could not build wheels for pyzmq, which is required to install pypproject.toml-based projects

When attempting to install JupyterLab 4.x on a version of Workbench that does not support JupyterLab 4.x:

ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.

jupyterlab 4.0.10 requires jupyter-server<3,>=2.4.0, but you have jupyter-server 1.24.0 which is incompatible.

notebook 7.0.6 requires jupyter-server<3,>=2.4.0, but you have jupyter-server 1.24.0 which is incompatible

Unfortunately, the highest version of Python supported by JupyterLab 3.6.6 is Python 3.11. Therefore, Python 3.11 is the highest currently supported version of Python within JupyterLab when used inside of Posit Workbench. 

Please note: Workbench itself does support up to 3.12, and you may use Python 3.12 with Workbench in other ways, e.g; Reticulate in the R IDE.

In order to install JupyterLab, at this time Posit recommends going through the steps in this document but for Python 3.11 or 3.10 instead of Python 3.12. E.g;

$ export PYTHON_VERSION=3.10
$ sudo /opt/python/${PYTHON_VERSION}/bin/pip install jupyter jupyterlab==3.6.6 rsp_jupyter rsconnect_jupyter workbench_jupyterlab==1.1.315

In the future, support for JupyterLab 4.x  is to be added, please check the release notes here. After that release has occurred, admins may upgrade Workbench to the version that supports JupyterLab 4.0.x and proceed to follow the installation instructions for the new version of Workbench if they wish to use Python 3.12 and above. As of January 2024, this release has not yet occurred and JupyterLab 4.0.x remains unsupported. 

For further assistance or any questions, licensed users may submit a Support Request.