OutputDriftRule class

A generated output holds keys the source does not — so the very next dialect sync will refuse.

check used to read dialect/source + dialect/translations and nothing else, which made this condition invisible to it. The cost is an ordering trap: the prescribed workflow is check --fix → sync → check, so a repo carrying orphans reports clean through the first command, through every edit made after it, and only refuses at the last step — on a condition that was already true before any of that work started. Nothing has to be redone, but half an hour passes between "knowable" and "known", and an agent will not invent a sync --dry-run preflight for a failure mode it has not met.

So check now answers the question it is asked first: is this repo in a state where sync can run?

It is a warning, not an error. Orphans are not incorrect translations — they are strings living in the wrong file, and everything still builds. But --strict promotes it, which is right for CI: a pipeline that regenerates outputs must not meet this for the first time mid-run.

The fix is never automatic. --fix normalizes ARB shape; deciding whether a hand-added key should be recovered (sync --adopt) or discarded (sync --prune) is a data-loss decision that belongs to a person.

Inheritance

Constructors

OutputDriftRule()
const

Properties

defaultSeverity IssueSeverity
Default severity. May be overridden per-issue.
no setteroverride
hashCode int
The hash code for this object.
no setterinherited
name String
Stable rule identifier (snake_case). Used by the report formatter to group findings and by users to silence/ack via state file (post-v1.0).
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
run(DialectProject project) List<Issue>
Inspect project and return findings. May return an empty list. Should NOT throw — turn unexpected conditions into Issues so the report surfaces them rather than crashing.
override
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited