feat(jupyter): add JupyterLab 4 and Notebook 7 companion extension POC - #742
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f012625067
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| "protocolVersion": PROTOCOL_VERSION, | ||
| "sessionId": str(walker.gid), | ||
| "name": name, | ||
| "props": walker._get_props(env="jupyter_extension"), |
There was a problem hiding this comment.
Omit sampled rows from kernel-mode props
When a nonempty DataFrame is opened, calling _get_props without data_source defaults to walker.origin_data_source, which contains up to 500 sampled rows even in kernel-computation mode. The companion therefore serializes and transfers those values in the open_dataframe response although the frontend ignores them; wide frames or columns containing large objects can substantially delay or even prevent the explorer from opening. Pass an empty data source here, as the existing anywidget kernel path does.
Useful? React with 👍 / 👎.
This adds an opt-in companion extension for JupyterLab 4.2+ and Notebook 7.2+. Users can select a live pandas DataFrame from the notebook kernel and explore it in a resizable host pane without inserting a
pyg.walk()cell. The existing anywidget workflow remains available.The companion reuses PyGWalker's frontend and kernel computation protocol. JupyterLab gets a sidebar and main-area document; Notebook 7 gets a toolbar entry, selector, and native right panel. The first POC supports one active explorer and top-level pandas variables.
Before merge, the review fixes isolate app CSS from notebook Markdown and Jupyter toolbars, pass the host palette into Graphic Walker and its menus, preserve charts across theme changes, and hide Save when there is no spec-file target. Graphic Walker is slotted into the isolated shell so its menu accessibility remains intact. The installation docs now include the separate Notebook 7 dependency.
Validation:
Known POC limits: kernel restart/reconnect and notebook-switch recovery remain Round 2 work, along with multiple explorers and persistence. There is no public package release in this PR. A rapid-theme-switch test encountered JupyterLab 4.2's own splash-screen removal race; the application flow passed after the host transition completed.
See
docs/JUPYTER_EXTENSION_ROADMAP.mdfor scope anddocs/JUPYTER_EXTENSION_POC_TEST.mdfor the acceptance procedure and recorded results.