Reviewers Conditions (autotransform.step.condition.reviewers)

The implementation for Conditions based on reviewers.

class autotransform.step.condition.reviewers.ReviewersCondition(*, comparison: ComparisonType, value: str | None = None)

Bases: ListComparisonCondition[str]

A condition which checks the reviewers for a Change.

comparison

The type of comparison to perform.

Type:

ComparisonType

value

The reviewer to check for. Defaults to None.

Type:

optional, Optional[str]

name

The name of the Component.

Type:

ClassVar[ConditionName]

comparison: ComparisonType
get_val_from_change(change: Change) List[str]

Gets the reviewers from the Change.

Parameters:

change (Change) – The Change the Condition is checking.

Returns:

The reviewers of the Change.

Return type:

List[str]

model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

name: ClassVar[ConditionName] = 'reviewers'
value: str | None
class autotransform.step.condition.reviewers.TeamReviewersCondition(*, comparison: ComparisonType, value: str | None = None)

Bases: ListComparisonCondition[str]

A condition which checks the team reviewers for a Change.

comparison

The type of comparison to perform.

Type:

ComparisonType

value

The team reviewer to check for. Defaults to None.

Type:

optional, Optional[str]

name

The name of the Component.

Type:

ClassVar[ConditionName]

comparison: ComparisonType
get_val_from_change(change: Change) List[str]

Gets the team reviewers from the Change.

Parameters:

change (Change) – The Change the Condition is checking.

Returns:

The team reviewers of the Change.

Return type:

List[str]

model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

name: ClassVar[ConditionName] = 'team_reviewers'
value: str | None