| Property | Value |
|---|---|
| Severity | Error |
| Category | Correctness |
| Default | Enabled |
Description
Detects cycles in the stage dependency graph. A cycle occurs when stages form mutual dependencies throughCOPY --from=<stage>, RUN --mount from=<stage>, or FROM <stage> references.
Circular dependencies always cause build failures because no stage in the cycle can finish
building before the others — each waits for output from another.
Common causes:
- A refactoring accidentally swaps stage references
- An AI-generated patch links stages in both directions
- A copy-paste introduces a forward
COPY --fromthat mirrors an existing backward reference