microsoft / vscode-jupyter

VS Code Jupyter extension
https://marketplace.visualstudio.com/items?itemName=ms-toolsai.jupyter
MIT License
1.29k stars 290 forks source link

Keep "Restart" button visible if the notebook loses focus #14317

Closed allefeld closed 10 months ago

allefeld commented 1 year ago

When the notebook editor loses focus to a regular editor, the "Restart" button in the toolbar disappears:

image

That is inconvenient because I often use another editor to edit a module (Python), and the notebook which imports this module needs to be restarted to import the new version.

The way it is is just a click more (click to focus the notebook then click on the "Restart" button), but in a longer development session that can still be a lot more clicks.

The behavior is also strange because the other notebook toolbar buttons remain visible, though they are just as applicable or inapplicable as the "Restart" button. Moreover, the button does not disappear if the focus in another notebook.

Please keep the "Restart" button visible even if the notebook loses focus.

rebornix commented 10 months ago
image

The restart button does persist when the notebook editor loses focus, but it only shows up if the kernel is live.