Skip to content
sarj/graph/contract-imports-implementation

Keep contracts implementation-free

Contracts depend only on other contracts.

error

Examples

FlaggedFails
contract --source-import--> product library
PassesClean
product contract --package-dependency--> shared contract

Why it matters

A contract coupled to implementation cannot remain a stable boundary.

How detection works

A contract has a code dependency on a non-contract component.

What is inspected

  • component kinds and declared code dependencies

How to fix it

Replace implementation coupling with an owned library or runtime contract.

  1. Keep contract dependencies limited to contract components.

Verify

  • Run repo-lint again and confirm the rule passes.