@task(...)
Decorator used to turn a function into a Prism task.
prism.decorators.task(
*, retries: int = 0, retry_delay_seconds: int = 0, targets: List[Callable] = []
)
Parameters
*
: indicates that thetask
decorator only accepts keyword arguments.retries
: total number of times to retry the task upon failure. Default is 0.retry_delay_seconds
: number of seconds to wait in between task retries. Default is 0.targets
: list oftarget
decorator calls. Default is an empty list.
Example: