class

Krikri::Lint::PartialBecomeRule

Inherits Krikri::Lint::Rule < Reference < Object

Upstream parity: partial-become (severity VERY_HIGH, tags unpredictability). become_user without a become at the same level is almost always a mistake: the task silently runs as whatever user, not the one named. Two sub-tags: partial-become[play] on a play, partial-become[task] on a task.

Constants

MESSAGE = "``become_user`` should have a corresponding ``become`` at the same level as itself."

Instance methods

applies_to
Source
check(file : PositionedFile, violations : Array(Violation)) : Nil
Source
marks_fixed?(violation : Violation) : Bool

Whether upstream's transform marks the given violation fixed. Transformable rules that do not mark it fixed get an "Rule specific fix not applied for" ERROR logged for the match.

Source
severity
Source
tags
Source
task_scoped?

Task-oriented: a # noqa: anywhere in the task's body suppresses the violation, as upstream's matchtask path does.

Source
transformable?

Upstream's transform rewrites the become/become_user pair and marks the match fixed, so no "not applied" is logged.

Source