PAIR-code / what-if-tool

Source code/webpage/demos for the What-If Tool
https://pair-code.github.io/what-if-tool
Apache License 2.0
923 stars 170 forks source link

Witwidget issue in JupyterLab #179

Open aishvarya opened 3 years ago

aishvarya commented 3 years ago

Hi there,

I am facing issues with WIT visualization in JupyterLab. Working in a miniconda environment with Python 3.8.5 and JupyterLab 3.1.7. Installed wit widget as instructed here (https://pair-code.github.io/what-if-tool/learn/tutorials/notebooks/). Here are my jupyterlab extensions after installing them;

JupyterLab v3.1.7
/Users/username/miniconda3/share/jupyter/labextensions
        @jupyter-widgets/jupyterlab-manager v3.0.0 enabled OK (python, jupyterlab_widgets)

Other labextensions (built into JupyterLab)
   app dir: /Users/username/miniconda3/share/jupyter/lab
        wit-widget v1.8.0 enabled OK

But when I load up my jupyter lab instance locally, I see the following error in the console,

Plugin 'wit-widget' failed to activate.
(anonymous) @ index.es6.js:283
index.es6.js:284 Error: No provider for: jupyter.extensions.jupyterWidgetRegistry.
    at W.e.resolveRequiredService (index.es6.js:198)
    at index.es6.js:156
    at Array.map (<anonymous>)
    at W.e.activatePlugin (index.es6.js:156)
    at index.es6.js:282
    at Array.map (<anonymous>)
    at W.e.start (index.es6.js:281)
    at q (index.out.js:625)

I already tried reinstalling the widget. Any pointers would be appreciated.

Thanks!

jameswex commented 3 years ago

I believe we haven't tested WIT in JupyterLab 3.x and it may not work. Have you attempted JupyterLab 2.x and if so, does that work for you? Please see https://github.com/PAIR-code/what-if-tool/issues/164 for more details.