-
Notifications
You must be signed in to change notification settings - Fork 28k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When no kernel is selected, notebook.cell.executeAndSelectBelow
cell insertion dismisses kernel picker
#128244
Comments
Let's take a look as we contribute shift-enter which just calls VS Code's command. It should popup the kernel. |
@claudiaregio I believe what's happening here is that the kernel picker comes up and then immediately disappears because the inserting a new cell into the notebook steals focus from the kernel picker. Can you confirm if that's what you're seeing too? shift+enter keybinding maps directly to vscode/src/vs/workbench/contrib/notebook/browser/notebookEditorKernelManager.ts Lines 38 to 42 in 3c9e29f
|
notebook.cell.executeAndSelectBelow
dismisses kernel picker and skips execution
notebook.cell.executeAndSelectBelow
dismisses kernel picker and skips executionnotebook.cell.executeAndSelectBelow
cell insertion dismisses kernel picker
The workspace edit to insert a new cell if the executed cell was the last one in the notebook dismisses the kernel picker. If there is already a cell below, focusing that cell doesn't dismiss the kernel picker. That is why it looks like shift+enter doesn't work the first time: on first shift+enter, there is no cell below, so we insert a cell; if you set focus back to the first cell and try again, there's already a cell below, so it just focuses that one. |
@roblourens I see that we intentionally defer evaluating |
@joyceerhl Yes, I see a really fast flash |
Environment data
Steps to Reproduce:
Expected behavior
To be prompted for a kernel and run after selection, then focus moves to next cell
Actual behavior
Focus moves to the next cell, I am not prompted to pick a kernel as none is selected for a new notebook.
Have to put focus back on the first cell and try shift + enter again
*Note: This does not occur if I open an existing notebook that has not been seen by VS Code before
The text was updated successfully, but these errors were encountered: