[API reference](https://evolu.dev/docs/api-reference) › [@evolu/common](https://evolu.dev/docs/api-reference/common) › [Task](https://evolu.dev/docs/api-reference/common/Task) › AnyAllFailed

```ts
type AnyAllFailed = "input" | "completion";
```

Defined in: [packages/common/src/Task.ts:3521](https://github.com/evoluhq/evolu/blob/e7144e2bbe9069362b62dec1b64a8aa922b8f1b0/packages/common/src/Task.ts#L3521)

Tie-breaker for [any](https://evolu.dev/docs/api-reference/common/Task/functions/any) when all tasks fail.

Used only when no task succeeds.

- `"input"` returns the error from the last task in the input array. This is
  stable under concurrency and generally produces deterministic tests.
- `"completion"` returns the error from the Task that finished last. This
  reflects timing but can vary across runs when task timing varies.

### Example

```ts
await using run = createRun();
const result = await run(
  concurrently(any([a, b, c], { allFailed: "completion" })),
);
```