Skip to content


Bases: _Entity, _Labeled

Hold a user function that will be executed, its parameters and the results.

A Task brings together the user code as function, the inputs and the outputs as data nodes (instances of the DataNode class).


Name Type Description
config_id str

The identifier of the TaskConfig.

properties dict[str, Any]

A dictionary of additional properties.

function callable

The python function to execute. The function must take as parameter the data referenced by inputs data nodes, and must return the data referenced by outputs data nodes.

input Union[DataNode, List[DataNode]]

The list of inputs.

output Union[DataNode, List[DataNode]]

The list of outputs.

id str

The unique identifier of the task.

owner_id str

The identifier of the owner (sequence_id, scenario_id, cycle_id) or None.

parent_ids Optional[Set[str]]

The set of identifiers of the parent sequences.

version str

The string indicates the application version of the task to instantiate. If not provided, the latest version is used.

skippable bool

If True, indicates that the task can be skipped if no change has been made on inputs. The default value is False.

scope: Scope property

Retrieve the lowest scope of the task based on its data nodes.


Type Description

The lowest scope present in input and output data nodes or GLOBAL if there are either no input or no output.


Returns the task simple label prefixed by its owner label.


Type Description

The label of the task as a string.


Get parents of the task.


Returns the task simple label.


Type Description

The simple label of the task as a string.

submit(callbacks=None, force=False, wait=False, timeout=None, **properties)

Submit the task for execution.


Name Type Description Default
callbacks List[Callable]

The list of callable functions to be called on status change.

force bool

Force execution even if the data nodes are in cache.

wait bool

Wait for the orchestrated job created from the task submission to be finished in asynchronous mode.

timeout Union[float, int]

The maximum number of seconds to wait for the job to be finished before returning.

**properties dict[str, any]

A keyworded variable length list of additional arguments.