Skip to content

Add retry feature #1540

@birdayz

Description

@birdayz

Make commands retryable:

...
tasks:
  build:
    retry:
      attempts: 3
      exit_codes:
        - 1
        - 127
    cmds:
     ...

If exit_codes is provided, only the provided exit codes are retryable. otherwise, all exit code are retried.

I have a use case, where a task runs many other tasks via deps. One of them fails, it all fails. In the end, CI retrys the entire task invocation, which will again run all of these parallel tasks. However, it would be much better to only retry the individual task that fails.
I can do the retry within the cmd, but that's not very elegant and re-usable i feel.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions