Chromium Code Reviews| Index: appengine/findit/templates/build_failure.html |
| diff --git a/appengine/findit/templates/build_failure.html b/appengine/findit/templates/build_failure.html |
| index b2a24207183439586384c2687df0dfdff99ed59d..3b0d103b2453389569d76f2c7585ec303299a03c 100644 |
| --- a/appengine/findit/templates/build_failure.html |
| +++ b/appengine/findit/templates/build_failure.html |
| @@ -253,6 +253,59 @@ |
| } |
| } |
| + function displayReliableFailuresToSheriffs(step_name, results) { |
| + if (!jQuery.isEmptyObject(results)) { |
| + var tableString = ''; |
| + $.each(results, function(index, result) { |
| + tableString += '<tr>'; |
| + |
| + var tryJob = result.try_job; |
| + var tryJobCulprit = tryJob.culprit; |
| + var rowspan = 1; |
| + |
| + if (jQuery.isEmptyObject(tryJobCulprit)) { |
| + rowspan = result.heuristic_analysis.suspected_cls.length > 0 ? result.heuristic_analysis.suspected_cls.length : 1; |
| + } |
| + tableString += generateCommonCellsForAllCategories(step_name, 'determined', index, result.tests, result.first_failure, result.last_pass, 1); |
| + |
| + if (! jQuery.isEmptyObject(tryJobCulprit)) { |
| + tableString += '<td rowspan="' + rowspan + '">Try Job</td>'; |
| + var build_number = result.try_job.try_job_key.split('/')[2]; // try_job_key would look like: 'master_name/builder_name/build_number'. |
|
stgao
2016/05/26 01:02:22
This is not related to this CL.
It seems not good
chanli
2016/05/26 20:15:13
I removed the comments, though I'm not sure exactl
stgao
2016/05/26 20:27:08
It's better for the try_job_key format to be restr
chanli
2016/05/26 21:22:25
Got it. I'll make the change in a separate CL.
|
| + tableString += '<td rowspan="' + rowspan + '"><a href="' + findit.builderUrl + '/builds/' + build_number + '">' + build_number + '</a></td>'; |
| + var review_url = tryJobCulprit.url || tryJobCulprit.review_url || (findit.defaultGitBaseUrl + tryJobCulprit.revision); |
| + tableString += '<td rowspan="' + rowspan + '"><a href="' + review_url + '">' + tryJobCulprit.commit_position || tryJobCulprit.revision + '</a></td>'; |
| + // Right now this cell is only for scores of heuristic results, placeholder for confidence in the future. |
| + tableString += '<td rowspan="' + rowspan + '">N/A</td>'; |
| + tableString += '<td rowspan="' + rowspan + '">'; |
| + tableString += '<li>Reliable failure: <a href="' + tryJob.task_url+ '">' + tryJob.task_id + '</a></li>'; |
| + if (tryJob.try_job_url) { |
| + tableString += '<li>For try job details: <a href="' + tryJob.try_job_url+ '">' + tryJob.try_job_build_number + '</a></li>'; |
| + } |
| + tableString += '</td>'; |
| + tableString += '<td rowspan="' + rowspan + '">Try job completed successfully.</td>'; |
| + |
| + } else { |
| + if (result.heuristic_analysis.suspected_cls.length > 0) { |
| + tableString += '<td rowspan="' + rowspan + '">Heuristic Analysis</td>'; |
| + tableString += generateHeuristicCulpritCls(result.heuristic_analysis.suspected_cls, result.supported); |
| + } else { |
| + var no_result_reason = 'Not Found'; |
| + if (! result.supported) { |
| + no_result_reason = 'Not Supported'; |
| + } |
| + tableString += '<td colspan="5" rowspan="' + rowspan + '">' + no_result_reason + '</td>'; |
| + } |
| + tableString += '<td rowspan="' + rowspan + '">' + findit.tryjobStatusMessageMap[tryJob.status] + '</td>'; |
| + } |
| + |
| + tableString += '</tr>'; |
| + }); |
| + |
| + $('#reliable_failures_sheriffs_table tbody').append(tableString); |
| + $('#reliable_failures_sheriffs').removeClass('not-display'); |
| + } |
| + } |
| + |
| function displayFlakyFailures(step_name, results) { |
| if (!jQuery.isEmptyObject(results)) { |
| var tableString = ''; |
| @@ -318,7 +371,11 @@ |
| $.each(findit.analysisResult, function(step_name, step_results) { |
| $.each(step_results.results, function(category, results) { |
| if (category == 'reliable_failures') { |
| + {% if show_debug_info %} |
| displayReliableFailures(step_name, results); |
| + {% else %} |
| + displayReliableFailuresToSheriffs(step_name, results); |
| + {% endif %} |
| } else if (category == 'unclassified_failures') { |
| displayUnclassifiedFailures(step_name, results); |
| } else if (category == 'flaky_failures') { |
| @@ -411,7 +468,7 @@ |
| </tr> |
| <tr> |
| <th colspan="3">Try Job Result</th> |
| - <th colspan="4">Heuristic Analysis Result</th> |
| + <th colspan="5">Heuristic Analysis Result</th> |
| </tr> |
| <tr> |
| <th title="The build cycle in which the CL was built or tested for the first time">Build Number</th> |
| @@ -429,22 +486,45 @@ |
| <br> |
| </div> |
| + <div id="reliable_failures_sheriffs" class='not-display'> |
| + <b>Reliable failures</b> |
| + <table id="reliable_failures_sheriffs_table"> |
| + <thead> |
| + <tr> |
| + <th rowspan="2" title="Failed step name" width="150px">Step</th> |
| + <th rowspan="2" title="Failed test name" width="300px">Test(s)</th> |
| + <th rowspan="2" title="The build cycle in which the step started to fail">First Failure</th> |
| + <th rowspan="2" title="The last build cycle in which the step passed">Last Pass<br>Before Failure</th> |
| + <th colspan="6">Suspected CLs</th> |
| + </tr> |
| + <tr> |
| + <th title="The source of result: Try Job or Heuristic Analysis.">Result Source</th> |
|
stgao
2016/05/26 01:02:22
"Result Source" --> "Analysis approach"? It would
chanli
2016/05/26 20:15:13
Done.
|
| + <th title="The build cycle in which the CL was built or tested for the first time">Build Number</th> |
| + <th title="Git commit position/hash">Commit</th> |
| + <th title="The higher score, the more suspected">Score (<a class="score-info" href="javascript:">?</a>)</th> |
| + <th title="Why this CL is related to the failure">Reason</th> |
| + <th title="Additional information such as the status of try job.">Note</th> |
| + </tr> |
| + </thead> |
| + <tbody> |
| + </tbody> |
| + </table> |
| + <br> |
| + </div> |
| + |
| <div id="flaky_failures" class='not-display'> |
| <b>Flaky failures</b> |
| <table id="flaky_failures_table"> |
| <thead> |
| <tr> |
| - <th rowspan="3" title="Failed step name" width="150px">Step</th> |
| - <th rowspan="3" title="Failed test name" width="300px">Test(s)</th> |
| - <th rowspan="3" title="The build cycle in which the step started to fail">First Failure</th> |
| - <th rowspan="3" title="The last build cycle in which the step passed">Last Pass<br>Before Failure</th> |
| - <th rowspan="3" title="link to swarming rerun">Swarming Rerun</th> |
| + <th rowspan="2" title="Failed step name" width="150px">Step</th> |
|
stgao
2016/05/26 01:02:22
Should we show that the result is from heuristic?
chanli
2016/05/26 20:15:13
Done.
|
| + <th rowspan="2" title="Failed test name" width="300px">Test(s)</th> |
| + <th rowspan="2" title="The build cycle in which the step started to fail">First Failure</th> |
| + <th rowspan="2" title="The last build cycle in which the step passed">Last Pass<br>Before Failure</th> |
| + <th rowspan="2" title="link to swarming rerun">Swarming Rerun</th> |
| <th colspan="4">Suspected CLs</th> |
| </tr> |
| <tr> |
| - <th colspan="4">Heuristic Analysis Result</th> |
| - </tr> |
| - <tr> |
| <th title="The build cycle in which the CL was built or tested for the first time">Build Number</th> |
| <th title="Git commit position/hash">Commit</th> |
| <th title="The higher score, the more suspected">Score (<a class="score-info" href="javascript:">?</a>)</th> |
| @@ -462,17 +542,14 @@ |
| <table id="unclassified_failures_table"> |
| <thead> |
| <tr> |
| - <th rowspan="3" title="Failed step name" width="150px">Step</th> |
| - <th rowspan="3" title="Failed test name" width="300px">Test(s)</th> |
| - <th rowspan="3" title="The build cycle in which the step started to fail">First Failure</th> |
| - <th rowspan="3" title="The last build cycle in which the step passed">Last Pass<br>Before Failure</th> |
| - <th rowspan="3" title="The reason why we're not sure about this result">Reason</th> |
| + <th rowspan="2" title="Failed step name" width="150px">Step</th> |
| + <th rowspan="2" title="Failed test name" width="300px">Test(s)</th> |
| + <th rowspan="2" title="The build cycle in which the step started to fail">First Failure</th> |
| + <th rowspan="2" title="The last build cycle in which the step passed">Last Pass<br>Before Failure</th> |
| + <th rowspan="2" title="The reason why we're not sure about this result">Reason</th> |
| <th colspan="4">Suspected CLs</th> |
| </tr> |
| <tr> |
| - <th colspan="4">Heuristic Analysis Result</th> |
| - </tr> |
| - <tr> |
| <th title="The build cycle in which the CL was built or tested for the first time">Build Number</th> |
| <th title="Git commit position/hash">Commit</th> |
| <th title="The higher score, the more suspected">Score (<a class="score-info" href="javascript:">?</a>)</th> |
| @@ -482,9 +559,10 @@ |
| <tbody> |
| </tbody> |
| </table> |
| + <br> |
| </div> |
| </div> |
| - <br> |
| + |
| <div class="thumbs-up-down"> |
| <b>Feedback on Findit result:</b><br> |
| <div class="triage thumb-up">Correct <img src="https://www.gstatic.com/images/icons/material/system/1x/thumb_up_black_24dp.png"/></div> |