Extension issues - shemaDir is empty: "./schema"

Hi all! I’m trying to add Widgets to JupyterLab. I’ve installed node js, but when I try to install @jupyter-widgets/jupyterlab-manager, I get the error: “@jupyter-widgets/jupyterlab-manager” is not a valid extension: schemaDir is empty: “./schema”. I’ve seen from other posts on this topic that you can go into the package and manually change the files (such as here: jupyterlab/jupyterlab - Gitter). However, I’m quite new to learning the structure of Python (I literally just learned how to use the terminal in JupyterLab yesterday). Can anyone help me figure out how to find the package and edit it? Or has anyone run into this issue that can give me some more advice? I’ve found the JupyterLab schemas extension manager package.json file, but editing it doesn’t change anything, so I’m not sure if I’m doing it wrong or if it’s the wrong file.

If you are working JupyterLab 3, you should only have to pip install ipywidgets (or conda install -c conda-forge ipywidgets) and the extension will be installed.

I would basically consider the built-in extension manager, and any instructions that tell you to get nodejs and jupyter labextension install (even the official ones) as probably outdated at this point, and more likely to mess up your environment than anything else.

Rather than trying to fix your existing environment, you may want to create, check-in, and keep update-to-date a requirements.txt:

# my interactive computing environment
jupyterlab >=3.4.5,<4
ipywidgets <8
# more things here

and python -m pip install -r requirements.txt in a virtual environment.

…or environment.yml:

name: my-env
  - conda-forge
  - nodefaults
  - jupyterlab >=3.4.5,<4
  - ipywidgets <8
  # ...more things here

and conda env update && conda activate my-env.


Thanks, I’ve done both pip install and conda install, and I don’t have any errors there, but then actually going to use the widget doesn’t work. It also seems to work fine in Notebook, just not Lab. This site (Installation — Jupyter Widgets 8.0.0rc2 documentation) is saying I might need to install ipywidgets and the extension into separate environments, but I only have the base environment. I’ve also updated Anaconda, still not working. Any ideas?

Ok, turns out I needed to update EVERYTHING - Anaconda, JupyterLab, and my computer - it’s working now! Thanks for your help

1 Like