Skip to content

Commit 4e1d104

Browse files
authored
Only run confirm-failures on 'trunk' branches. (#8870)
1 parent 9e3c07e commit 4e1d104

File tree

1 file changed

+20
-28
lines changed

1 file changed

+20
-28
lines changed

ui/shared/BugFiler.jsx

Lines changed: 20 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -390,12 +390,12 @@ export class BugFilerClass extends React.Component {
390390
comment,
391391
isIntermittent,
392392
isSecurityIssue,
393-
launchConfirmFailure,
394393
checkedLogLinks,
395394
regressedBy,
396395
seeAlso,
397396
keywords,
398397
crashSignatures,
398+
launchConfirmFailure,
399399
} = this.state;
400400
const { toggle, successCallback, notify, suggestions } = this.props;
401401

@@ -475,6 +475,7 @@ export class BugFilerClass extends React.Component {
475475
) {
476476
priority = '--';
477477
}
478+
478479
if (launchConfirmFailure && keywords.includes('intermittent-testcase')) {
479480
// Launch confirm failure task
480481
this.handleConfirmFailure();
@@ -614,7 +615,6 @@ export class BugFilerClass extends React.Component {
614615
parsedLog,
615616
fullLog,
616617
reftestUrl,
617-
selectedJob,
618618
currentRepo,
619619
} = this.props;
620620
const {
@@ -635,18 +635,6 @@ export class BugFilerClass extends React.Component {
635635
const crashSignatures = getCrashSignatures(suggestion);
636636
const unhelpfulSummaryReason = this.getUnhelpfulSummaryReason(summary);
637637

638-
let launchCF = launchConfirmFailure;
639-
640-
if (
641-
['autoland', 'mozilla-central', 'try'].includes(currentRepo.name) &&
642-
!selectedJob.job_type_name.toLowerCase().includes('backlog') &&
643-
!selectedJob.job_type_name.toLowerCase().includes('-verify')
644-
) {
645-
// no-op
646-
} else {
647-
launchCF = false;
648-
}
649-
650638
return (
651639
<div>
652640
<Modal isOpen={isOpen} toggle={toggle} size="lg">
@@ -933,20 +921,24 @@ export class BugFilerClass extends React.Component {
933921
Report this as a security issue
934922
</Label>
935923
</div>
936-
<div className="d-inline-flex mt-2 ml-5">
937-
<Label>
938-
<Input
939-
type="checkbox"
940-
checked={launchCF}
941-
onChange={() =>
942-
this.setState({
943-
launchConfirmFailure: !launchCF,
944-
})
945-
}
946-
/>
947-
Launch the Confirm Failures task at bug submission
948-
</Label>
949-
</div>
924+
{['autoland', 'mozilla-central', 'try'].includes(
925+
currentRepo.name,
926+
) && (
927+
<div className="d-inline-flex mt-2 ml-5">
928+
<Label>
929+
<Input
930+
type="checkbox"
931+
checked={launchConfirmFailure}
932+
onChange={() =>
933+
this.setState({
934+
launchConfirmFailure: !launchConfirmFailure,
935+
})
936+
}
937+
/>
938+
Launch the Confirm Failures task at bug submission
939+
</Label>
940+
</div>
941+
)}
950942
{!!crashSignatures.length && (
951943
<div>
952944
<Label for="signature-input">Signature:</Label>

0 commit comments

Comments
 (0)