| OLD | NEW |
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 from collections import defaultdict | 5 from collections import defaultdict |
| 6 from datetime import datetime | 6 from datetime import datetime |
| 7 | 7 |
| 8 from google.appengine.api import users | 8 from google.appengine.api import users |
| 9 | 9 |
| 10 from common import constants | 10 from common import constants |
| (...skipping 311 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 322 'pipeline_status_path': analysis.pipeline_status_path, | 322 'pipeline_status_path': analysis.pipeline_status_path, |
| 323 'show_debug_info': self._ShowDebugInfo(), | 323 'show_debug_info': self._ShowDebugInfo(), |
| 324 'analysis_request_time': _FormatDatetime(analysis.request_time), | 324 'analysis_request_time': _FormatDatetime(analysis.request_time), |
| 325 'analysis_start_time': _FormatDatetime(analysis.start_time), | 325 'analysis_start_time': _FormatDatetime(analysis.start_time), |
| 326 'analysis_end_time': _FormatDatetime(analysis.end_time), | 326 'analysis_end_time': _FormatDatetime(analysis.end_time), |
| 327 'analysis_duration': analysis.duration, | 327 'analysis_duration': analysis.duration, |
| 328 'analysis_update_time': _FormatDatetime(analysis.updated_time), | 328 'analysis_update_time': _FormatDatetime(analysis.updated_time), |
| 329 'analysis_completed': analysis.completed, | 329 'analysis_completed': analysis.completed, |
| 330 'analysis_failed': analysis.failed, | 330 'analysis_failed': analysis.failed, |
| 331 'analysis_correct': analysis.correct, | 331 'analysis_correct': analysis.correct, |
| 332 'analysis_is_duplicate': analysis.is_duplicate, |
| 332 'triage_history': _GetTriageHistory(analysis), | 333 'triage_history': _GetTriageHistory(analysis), |
| 333 'show_triage_help_button': self._ShowTriageHelpButton(), | 334 'show_triage_help_button': self._ShowTriageHelpButton(), |
| 335 'triage_reference_analysis_master_name': |
| 336 analysis.triage_reference_analysis_master_name, |
| 337 'triage_reference_analysis_builder_name': |
| 338 analysis.triage_reference_analysis_builder_name, |
| 339 'triage_reference_analysis_build_number': |
| 340 analysis.triage_reference_analysis_build_number |
| 334 } | 341 } |
| 335 | 342 |
| 336 def _PrepareDataForCompileFailure(self, analysis): | 343 def _PrepareDataForCompileFailure(self, analysis): |
| 337 data = self._PrepareCommonDataForFailure(analysis) | 344 data = self._PrepareCommonDataForFailure(analysis) |
| 338 | 345 |
| 339 # Check result from heuristic analysis. | 346 # Check result from heuristic analysis. |
| 340 _PopulateHeuristicDataForCompileFailure(analysis, data) | 347 _PopulateHeuristicDataForCompileFailure(analysis, data) |
| 341 # Check result from try job. | 348 # Check result from try job. |
| 342 data['try_job'] = _PrepareTryJobDataForCompileFailure(analysis) | 349 data['try_job'] = _PrepareTryJobDataForCompileFailure(analysis) |
| 343 | 350 |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 403 } | 410 } |
| 404 else: | 411 else: |
| 405 return { | 412 return { |
| 406 'template': 'build_failure.html', | 413 'template': 'build_failure.html', |
| 407 'data': self._PrepareDataForTestFailures(analysis, build_info, | 414 'data': self._PrepareDataForTestFailures(analysis, build_info, |
| 408 self._ShowDebugInfo()), | 415 self._ShowDebugInfo()), |
| 409 } | 416 } |
| 410 | 417 |
| 411 def HandlePost(self): # pragma: no cover | 418 def HandlePost(self): # pragma: no cover |
| 412 return self.HandleGet() | 419 return self.HandleGet() |
| OLD | NEW |