Skip to main content

Execution

Represents the result of a cell execution.

Constructors

Parameters
Returns
Execution

Properties

Accessors

text

Returns the text representation of the main result of the cell.
Returns
undefined | string

Methods

toJSON()

Returns the serializable representation of the execution result.
Returns
object

ExecutionError

Represents an error that occurred during the execution of a cell. The error contains the name of the error, the value of the error, and the traceback.

Constructors

Parameters
Returns
ExecutionError

Properties


OutputMessage

Represents an output message from the sandbox code execution.

Constructors

Parameters
Returns
OutputMessage

Properties

Methods

toString()

Returns
string

Result

Represents the data to be displayed as a result of executing a cell in a Jupyter notebook. The result is similar to the structure returned by ipython kernel: https://ipython.readthedocs.io/en/stable/development/execution.html#execution-semantics The result can contain multiple types of data, such as text, images, plots, etc. Each type of data is represented as a string, and the result can contain multiple types of data. The display calls don’t have to have text representation, for the actual result the representation is always present for the result, the other representations are always optional.

Constructors

Parameters
Returns
Result

Properties

Methods

formats()

Returns all the formats available for the result.
Returns
string[] Array of strings representing the formats available for the result.

toJSON()

Returns the serializable representation of the result.
Returns
object

Type Aliases

Logs

Data printed to stdout and stderr during execution, usually by print statements, logs, warnings, subprocesses, etc.

Type declaration


MIMEType

Represents a MIME type.

RawData

Dictionary that maps MIME types to their corresponding representations of the data.

Functions

extractError()

Parameters

Returns

Promise<undefined | SandboxError>

parseOutput()

Parameters

Returns

Promise<void>