LoginSignup
12
10

More than 3 years have passed since last update.

Jupyter labの拡張機能(Variable inspector)がインストール済みなのに動作しない(Uninstalled core extensions)

Last updated at Posted at 2020-07-23

日本語ではこのバグについて見つけられず時間がかかってしまったので一応記録しておきます。

症状

jupyterlabの拡張機能の一つであるVariable inspectorがインストール済みにも関わらず機能しなくなった。具体的には、通常タブ内で右クリックすると"Open Variable inspector"が出てきて開くことができるのだが、その文字すら一向に出てこなくなってしまった。jupyterlabの再インストール,バージョンの変更、Variable inspectorのアンインストールなど行ってみたが全く効果なし。
環境:macOS,zsh,pip

以下を行うとjupyterlabのインストール済みの拡張機能が見られる。

$ jupyter labextension list
JupyterLab v2.0.1
Known labextensions:
   app dir: /Users/ユーザ名/.pyenv/versions/3.8.3/share/jupyter/lab
        @lckr/jupyterlab_variableinspector v0.5.1  enabled  OK

Uninstalled core extensions:
    @lckr/jupyterlab_variableinspector

インストール済みのはずなのになぜかuninstalldになってしまっている。

僕はこれで直りました

調べてみるとどうやらbuild_config.jsonというログファイル?が悪さしてるらしい。開いてみます、

$ open /Users/ユーザ名/.pyenv/versions/3.8.3/share/jupyter/lab/settings/build_config.json
build_config.json
{
    "uninstalled_core_extensions": [
        "@lckr/jupyterlab_variableinspector"
    ]
}

見つけた。

build_config.jsonファイルを削除して、もう一度

$ jupyter labextension list

実行すると、buildをお勧めされるので、指示に従ってbuildする。

$ jupyter lab build
$ jupyter labextension list
JupyterLab v2.0.1
Known labextensions:
   app dir: /Users/ユーザ名/.pyenv/versions/3.8.3/share/jupyter/lab
        @lckr/jupyterlab_variableinspector v0.5.1  enabled  OK

uninstalldは無事なくなってjupytarlab再起動後無事Variable inspector復活。
おそらくバグ。何がきっかけでこうなったのかがわからなかったから怖かったです。

参考

以下の記事にもいろいろ書いてあります。
https://discourse.jupyter.org/t/extension-shows-up-as-both-installed-and-uninstalled-and-doesnt-work/2688/3
https://github.com/krassowski/jupyterlab-lsp/issues/203

12
10
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
12
10