-
Notifications
You must be signed in to change notification settings - Fork 35.7k
Closed
microsoft/vscode-jupyter
#6550Labels
feature-requestRequest for new features or functionalityRequest for new features or functionalityon-testplan
Milestone
Description
Explore how to replace the webview interactive in Jupyter extension with a built in one with better workbench integration and leverage the existing notebook ecosystem.
Prototype
- Core
-
ctrl+enteron the code editor widget as a command/kb:interacive.execute- execute, get active text editor, get the content, find the notebook document, apply worksapce edit
- request execution on cell
notebook.cell.execute(argument isCellRange)
- Make this document readonly
- setting
interactive.experiments.enable - Swap menu ids for interactive editor (
notebook/toolbartointeractive/toolbar)
-
- Jupyter
- register controllers for
interactive - contribute commands/codelens when
config.interactive.experiments.enableBuiltinEditor == true - remove decorations for cell editors in the interactive window
- when a controller is selected by the document, then insert a markdown cell
- collapse all cell inputs by default
- register controllers for
Snapshot of how it looks integrated together:
Issues unveiled from prototype:
- Affinity doesn't always work, might be caused by no
activeNotebokkEditorChangeevent. - register intellisense for input editor. This would require some rewrite as it will need to read the
NotebookDocumentin the IW. - Variables View is global and depends on
activeNotebook - Initial kernel/sys info: in traditional interactive window / repl, when the window/repl is started, there is a printed message about the environment (e.g.,
Python 3.8, balabal). The info is only known after the underling jupyter kernel is started, so if users open Interactive Window first, and shift+enter to execute code from the input editor, we insert a code cell first before the kernel gets a change to print the kernel info.
Backlog
-
Core
- Customized theme tokens for notebook in the interactive window
- Improve styles for input editor in interactive window
- Clearer UI indication that interactive window is readonly (e.g. cell editor background color, no drag and drop feedback)
- Collapsed cell input for code cells submitted from a script file, with just the first line of code shown
-
Jupyter
- Implement variables view
- Interactive window multiple, single, perFile settings
- Preserve #%% comments in cell metadata and restore during export
- IPyWidgets support
- Merge exporting to notebook with existing quickpick
- Debug cell
- Support executing markdown cells from a script file in the interactive window
- Support exporting markdown cells from interactive window (preserving language, cell type etc)
- Add a setting to export to Python script without preserving cell delimiters
- Suppress language server intellisense for TextDocuments in embedded NotebookDocuments (handled by the core)
matijagrcic, scsleal, renkun-ken and domiden
Metadata
Metadata
Labels
feature-requestRequest for new features or functionalityRequest for new features or functionalityon-testplan
