Skip to content

Lint Rules

Lint rules surface diagnostics without rewriting source. They run under both prose check and prose format, returning exit code 2 when any lint diagnostic fires, and they never produce an Edit. Lint coincides with its domain, in that every lint rule sits in the lint domain and every rule in the lint domain is a lint. The category-versus-domain distinction collapses cleanly to one landing.

bare-imports

Lint

Prose surfaces a narrowly-used bare import that from x import … would replace.

legacy-union-syntax

Lint

Prose surfaces Union[A, B] and Optional[T] patterns that should read as modern A | B and T | None.

reassigned-constants

Lint

Prose surfaces a module-level constant reassigned despite its UPPER_SNAKE_CASE casing.

single-use-variables

Lint

Prose surfaces single-use local bindings that could inline cleanly.

step-narration

Lint

Prose surfaces comments that narrate the next line.

Each lint surfaces a pattern Prose notices but won't itself resolve, because the right fix depends on intent the binary can't infer. The Suppression chapter covers per-line opt-outs via # prose: ignore[<rule>]. The Exit Codes reference covers the gating semantics. For the auto-fix companion landing, see the Auto-Fix Rules page. For the per-rule enabled knob, see the Configuration reference.