Module to detect the currently running cell.
The notebook sends execution requests, and they queue up on the message channel.
There is no straight forward way to detect the currently running cell.
Here we use a queue to store execution requests and dequeue elements as the kernel becomes idle after the requests
Members
-
<inner> cell_queue
-
The list of cells queued for execution.
Methods
-
<inner> cell_execute_called()
-
Called when an execute.CodeCell event occurs. This means an execute request was sent for the current cell.
-
<inner> cell_execute_finished()
-
Called when the kernel becomes idle. This means that a cell finished executing.
-
<inner> getRunningCell()
-
Returns:
- The running cell, or null.- Type
- CodeCell
-
<inner> getLastCell()
-
Returns:
- The last run cell, or null.- Type
- CodeCell
-
<inner> cell_deleted(event, data)
-
Called when a cell is deleted
Parameters:
Name Type Description event
event The event object, data
data data of the event, contains the cell -
<inner> register()
-
Register event listeners for detecting running cells.