Custom Tasks#

Tags: Extensibility, Intermediate

Flytekit ships with an extensible task system, which makes it easy for anyone to extend and add new task types.

Refer to the Prebuilt container task plugins and User container task plugins guides if you’d like to contribute a new task type.

flytekit.core.base_task#

kwtypes(**kwargs)

This is a small helper function to convert the keyword arguments to an OrderedDict of types.

PythonTask(*args, **kwargs)

Base Class for all Tasks with a Python native Interface.

Task(task_type, name, interface[, metadata, ...])

The base of all Tasks in flytekit.

TaskResolverMixin()

Flytekit tasks interact with the Flyte platform very, very broadly in two steps.

IgnoreOutputs

This exception should be used to indicate that the outputs generated by this can be safely ignored.

flytekit.core.python_function_task#

PythonFunctionTask(*args, **kwargs)

A Python Function task should be used as the base for all extensions that have a python function.

PythonInstanceTask(*args, **kwargs)

This class should be used as the base class for all Tasks that do not have a user defined function body, but have a platform defined execute method.