plynx.plugins.executors.python.local

Python Operation

Module Contents

plynx.plugins.executors.python.local.DEFAULT_CMD = # Python Operation[source]

System Message: WARNING/2 (/home/docs/checkouts/readthedocs.org/user_builds/plynx/checkouts/latest/docs/_api/plynx/plugins/executors/python/local/index.rst, line 17)

Explicit markup ends without a blank line; unexpected unindent.

# The code of the operation have to be defined as a function # # A function must be named operation. # The arguments are named and must represent then inputs of the PLynx Operation. # The function must return a dictionary that map to the outputs of PLynx Operation def operation(int_a, int_b):

System Message: ERROR/3 (/home/docs/checkouts/readthedocs.org/user_builds/plynx/checkouts/latest/docs/_api/plynx/plugins/executors/python/local/index.rst, line 23)

Unexpected indentation.
return {“sum”: int_a + int_b}
plynx.plugins.executors.python.local.stateful_init_mutex[source]
plynx.plugins.executors.python.local.stateful_class_registry[source]
plynx.plugins.executors.python.local._resource_manager[source]
plynx.plugins.executors.python.local.materialize_fn_or_cls(node: Node) → Callable[source]

Unpickle the function

plynx.plugins.executors.python.local.assign_outputs(node: Node, output_dict: Dict[str, Any])[source]

Apply output_dict to node’s outputs.

class plynx.plugins.executors.python.local.redirect_to_plynx_logs(node: Node, stdout: str, stderr: str)[source]

Redirect stdout and stderr to standard PLynx Outputs

__enter__(self)[source]
__exit__(self, *args)[source]
plynx.plugins.executors.python.local.prep_args(node: Node) → Dict[str, Any][source]

Pythonize inputs and parameters

class plynx.plugins.executors.python.local.PythonNode[source]

Bases: plynx.plugins.executors.bases.PLynxSyncExecutor

Class is used as a placeholder for local python executor

run(self, preview: bool = False)[source]
kill(self)[source]
classmethod get_default_node(cls, is_workflow: bool)[source]

Generate a new default Node for this executor