# `failure.invalid_covers_nothing`

Catch-all covers no rule, because every rule that can break has an arm.

Area 4, [Failures](../topics/failures.md); not declinable; the next step is usually the agent's.

```jadpo
type Quantity = Int {
    min: 1
    max: 1000
}

type QuantityTooLarge = Failure {
    kind: FailureKind.invalid_value
}

type QuantityRefused = Failure {
    kind: FailureKind.invalid_value
}

function doubled(quantity: Quantity) fails QuantityTooLarge, QuantityRefused -> Quantity {
    var result: Quantity = attempt Quantity(quantity * 2) {
        max: QuantityTooLarge
        invalid: QuantityRefused
    }
    return result
}
```

```text
error: `invalid:` covers nothing here
 --> main.jadpo:17:9
   |
17 |         invalid: QuantityRefused
   |         ^^^^^^^ no rule left to cover
  reason: Every rule `Quantity(...)` can break has its own arm (`max`), so `invalid:` could never run.
  next: Remove `invalid: ...` (agent)
  rule: failure.invalid_covers_nothing
  help: https://jadpo.dev/docs/errors/failure.invalid_covers_nothing

check failed: 1 error, 1 file
```
