#author("2025-10-28T09:42:43+00:00","default:iseki","iseki") #author("2025-10-28T09:42:55+00:00","default:iseki","iseki") * JupyterLab [#y35473e3] - Jupyter Notebookの後継. WebアプリケーションによるIDE - Tab 形式の [[Jupyter]] UI ** 開発 [#p55693ec] - 開発者用ドキュメント https://jupyterlab.readthedocs.io/en/stable/extension/extension_dev.html - https://github.com/jupyterlab/extension-cookiecutter-ts - [[jnotice>./jnotice] [[LTIContainerSpawner]] 用 通知プラグイン - [[jnotice>./jnotice]] : [[LTIContainerSpawner]] 用 通知プラグイン *** Localization [#z14cb2cf] - https://jupyterlab.readthedocs.io/en/stable/extension/internationalization.html ** Install [#f74258cb] (base) # conda install -c conda-forge jupyterlab -y ** 設定 [#n53dd1dd] *** [[JupyterHub]] [#zb703e5c] - ''jupyterhub_config.py'' で ''c.Spawner.default_url = '/lab''' とする *** Notebook [#k830acdc] - アクセス中にクラシックノートブックにアクセスするには ''/user/{username}/tree'' にアクセス -- /lab に戻るには ''/user/{username}/lab'' にアクセス *** 起動 [#uc6415cc] **** コンソール起動 [#bc50afdb] jupyter lab --allow-root --ip=0.0.0.0 ** Command [#ucb0d3d2] **** Update [#gaa53fb8] - conda update -c conda-forge jupyterlab - jupyter labextension update --all -- Node.js(nodejs >=12.0.0)が必要 **** Version [#p44ac111] - jupyter lab --version ** カーネル [#n98ed3b5] ** 拡張機能 [#gc7026e3] - https://www.hinomaruc.com/jupyter-notebook-five-extensions-recommendation/ *** labextensions [#sb566b8b] **** 一覧 [#i0320572] jupyter labextension list **** uninstall [#i5d92b23] jupyter labextension uninstall ..... - 削除できない場合 -- pip でインストールしている場合は pip uninstall ... -- 開発環境でインストールしている場合は jupyter labextension list で表示されたシンボリックリンクを消す. --- jupyter labextension list では - だが,ファイル名は _ になっている場合がある. *** python3-matplotlib [#p7437da2] yum install --enablerepo "powertools" python3-matplotlib *** ipyturtlenext [#f07026ef] - まともに動くTurtle - ipyturtle とかはまともに動かん(JupyterLabのバージョンのせいか?) *** metakernel [#if83493c] - jigsaw 面白そう *** [[JupyterLab-Blockly]] [#q2684645] **** 開発 Install [#t3a1bfb6] git clone https://github.com/QuantStack/jupyterlab-blockly.git cd jupyterlab-blockly pre-commit install # 多分いらない pip install -e ".[dev]" jupyter labextension develop . --overwrite jlpm build chmod -R a+rx . # 必要に応じて **** Uninstall [#kcd5b08c] pip uninstall jupyterlab_blockly **** Packaging [#rbf9909f] pip install build twine python -m build - pip install build twine は一回だけ - python -m build で dist/ に tar Ball ができる. - tar Ball は jupyter labextension install tar_ball でインストール **** Bug [#bcd7a65d] - 0.3.0a から テキストがブロックからはみ出すバグあり. *** jupyterlab-tabular-data-editor [#z6bf444d] - CSVファイルの編集 **** 開発 install [#x35e2f99] git clone https://github.com/jupytercalpoly/jupyterlab-tabular-data-editor.git cd jupyterlab-tabular-data-editor pip install -e . jupyter labextension develop . --overwrite vi tsconfig.json jlpm build chmod -R a+rx . # 必要に応じて - コンパイルするには tsconfig.json の修正が必要 - "target": "es2017", + "target": "es2018", + "skipLibCheck": true, **** Uninstall [#gd7b8826] pip uninstall jupyterlab-tabular-data-editor ** Trouble Shooting [#f652ceef] *** Javascript Error: IPython is not defined [#a78cc9c2] - %matplotlib notebook で Javascript Error: IPython is not defined のエラーが出る. - %matplotlib widget を使用する(要カーネル再起動).