---
title: ConstraintError
framework: lightweightcoderequirements
role: symbol
role_heading: Enumeration
path: lightweightcoderequirements/constrainterror
---

# ConstraintError

Error types that can be thrown from lightweight code requirement routines.

## Declaration

```swift
enum ConstraintError
```

## Topics

### Enumeration Cases

- [ConstraintError.duplicateKey](lightweightcoderequirements/constrainterror/duplicatekey.md)
- [ConstraintError.malformedConstraint](lightweightcoderequirements/constrainterror/malformedconstraint.md)
- [ConstraintError.taskIsNoLongerValid](lightweightcoderequirements/constrainterror/taskisnolongervalid.md)
- [ConstraintError.unsupportedConstraintForRequirementType](lightweightcoderequirements/constrainterror/unsupportedconstraintforrequirementtype.md)

## Relationships

### Conforms To

- [Equatable](swift/equatable.md)
- [Error](swift/error.md)
- [Escapable](swift/escapable.md)
- [Hashable](swift/hashable.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)
