Automatically set correct renderer for Plotly charts in VSCode Notebooks
まだ誰も着手していません。
- 主要言語
- Python
- スター
- 18.8k
- フォーク
- 2.8k
- 平均マージ
- 16時間 26分
- マージ済み PR(30日)
- 21
説明
Because https://github.com/microsoft/vscode-notebook-renderers/pull/199 is unmerged, users of Plotly.py using the VSCode notebooks cannot access the latest Plotly.js/Plotly.py features and no discernible error message is provided. This leads to confusion, because users are working with the latest version of Plotly.py and their charts don't work properly.
This has caused issues for adoption of new features like MapLibre and subtitles in charts, and may others. See e.g.:
- https://github.com/plotly/plotly.py/issues/4715
- https://github.com/plotly/plotly.py/issues/4775
- https://github.com/plotly/plotly.py/issues/4701
- https://github.com/plotly/plotly.py/issues/4583
- https://github.com/plotly/plotly.py/issues/4560
- https://github.com/plotly/plotly.py/issues/4475
- https://github.com/plotly/plotly.py/issues/4528
- https://github.com/plotly/plotly.py/issues/4264
- https://github.com/plotly/plotly.py/issues/4173
- https://github.com/plotly/plotly.py/issues/4094
Developers can workaround this by adding to their notebook:
import plotly.io as pio
pio.renderers.default = "notebook_connected"
While this is trivial to change, it's undiscoverable and non-intuitive. If you have the latest version of Plotly.py installed, you should be able to use the latest features in any Python environment!
Regardless of whether https://github.com/microsoft/vscode-notebook-renderers/pull/199 is merged, this dependency means VSCode Notebook users will always lag behind Plotly.py releases as we wait for VSCode to adopt and release their own updates, which means VSCode users would never have day-of updates without a workaround 🙁
Is it possible to detect that we're in a VSCode Notebook environment and automatically set the correct renderer to avoid this dependency on a VSCode update?
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
リポジトリのファイルやテストは指定されていません。まず、plotly.io を通じて公開されている renderer の設定、特にエントリーポイント pio.renderers.default を読み、notebook 環境がどのように識別されるかを調査してください。VSCode Notebook のユーザーが、ドキュメント化された workaround を追加しなくても、現在互換性のある renderer を自動的に受け取れるようになり、検出動作がカバレッジで確認されていれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- javascript, jupyter-notebook, python
- 領域
- data-visualization, tooling
- issue の種類
- 機能追加
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 35/100