Skip to content

Commit a816dbf

Browse files
committed
PreventPathCheckMixin: rename error_message to error_cause_details
1 parent d60bec6 commit a816dbf

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/lando/utils/landing_checks.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ class PreventPathCheckMixin(ABC):
8282
override_commit_message: str
8383
a string to allow users to bypass the check
8484
85-
error_message: str
85+
error_cause_details: str
8686
a basic error string to show before the list of matching files (no colon
8787
needed)
8888
@@ -97,7 +97,7 @@ class PreventPathCheckMixin(ABC):
9797

9898
paths: list[re.Pattern]
9999
override_commit_message: str
100-
error_message: str
100+
error_cause_details: str
101101

102102
disallowed_changes: list[str] = field(init=False)
103103

@@ -118,7 +118,7 @@ def build_error_message(self) -> str:
118118
return_error_message = [self.BASE_ERROR_MESSAGE]
119119

120120
if self.disallowed_changes:
121-
return_error_message.append(f"{self.error_message}:")
121+
return_error_message.append(f"{self.error_cause_details}:")
122122
return_error_message.append(wrap_filenames(self.disallowed_changes))
123123

124124
return f"{' '.join(return_error_message)}."
@@ -154,7 +154,7 @@ class PreventDotGithubCheck(PreventPathCheckMixin, PatchCheck):
154154
re.compile("^.github/workflows"),
155155
]
156156
override_commit_message = "DOT_GITHUB_OVERRIDE"
157-
error_message = "GitHub workflows directory"
157+
error_cause_details = "GitHub workflows directory"
158158

159159
@override
160160
@classmethod
@@ -175,7 +175,7 @@ class PreventNSPRCheck(PreventPathCheckMixin, PatchCheck):
175175
re.compile("^nsprpub/"),
176176
]
177177
override_commit_message = "UPGRADE_NSPR_RELEASE"
178-
error_message = "vendored NSPR directories"
178+
error_cause_details = "vendored NSPR directories"
179179

180180
@override
181181
@classmethod
@@ -196,7 +196,7 @@ class PreventNSSCheck(PreventPathCheckMixin, PatchCheck):
196196
re.compile("^security/nss/"),
197197
]
198198
override_commit_message = "UPGRADE_NSS_RELEASE"
199-
error_message = "vendored NSS directories"
199+
error_cause_details = "vendored NSS directories"
200200

201201
@override
202202
@classmethod

0 commit comments

Comments
 (0)