Jupyterlab: [feature request] Execute selected notebook code in console keyboard-sc / context menu option

Created on 19 Mar 2018  路  3Comments  路  Source: jupyterlab/jupyterlab

Hi,

For productivity, it would be super useful to send selected code/cell code to be executed in the attached console.

Why:
The console attached to a notebook usually is used for debugging and experimentation, the notebook contains the eventual final "production" code - minimal and concise. Often during experimentation, you want to execute code snippets in the console and observe the output. Currently, this can be done by selecting the code, copying it to the clipboard, moving the mouse to the console tab (or using a keyboard sc) pasting the code in the console and pressing enter. Long sequence, done many times.

It would be very useful to just highlight the text/cell, and press an "evaluate in console" key combination. the focus will shift to the console and the code will be executed there.
WDYT?

notebook Enhancement

Most helpful comment

I think this sounds like a great idea.

All 3 comments

I think this sounds like a great idea.

This is achieved in Jupyter through the Ctrl-Shift-Enter shortcut in SoS Notebook extension, see this blog post for details.

SoS Notebook is being ported to JupyterLab. This particular feature has been discussed in #3453 and will be implemented for SoS. I do plan to submit a pull request to make this feature available for all kernels though.

@BoPeng Thanks for the links. I think this functionality is important enough to have it separate to a different, less common need extension.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ClaytonPassmore picture ClaytonPassmore  路  3Comments

psinger picture psinger  路  3Comments

dhirschfeld picture dhirschfeld  路  3Comments

bollwyvl picture bollwyvl  路  3Comments

discdiver picture discdiver  路  3Comments