diff options
author | Caroline Tice <cmtice@google.com> | 2015-09-08 16:28:57 -0700 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2015-09-10 17:05:06 -0700 |
commit | 9b852cfd9a602c5f80c8e621c696b796ce5177fd (patch) | |
tree | 63addd9a3cefaaabdc72b2668226480f84016125 /crosperf/results_report.py | |
parent | f63421f72bc7606ce8bfc04ce9acf25e3bf8c4c0 (diff) | |
download | toolchain-utils-9b852cfd9a602c5f80c8e621c696b796ce5177fd.tar.gz |
Store machine description info in cache and json reports.
This CL updates the cache mechanism to store the machine spec
info (the checksum string) in the cache, as well as storing the
machine information in the json reports (to go into the dashboard
archive). It also updates the json reports to always include the
full set of result fields for a test, and it verifies that the
old cache directory exists before trying to remove it.
BUG=None
TEST=Tested in my directory, with --cache_only=True, --rerun=True and
--json_report=True
Change-Id: Ib12bae4ca10141de0b972e3a7aeee83c7b59049b
Reviewed-on: https://chrome-internal-review.googlesource.com/229765
Commit-Ready: Caroline Tice <cmtice@google.com>
Tested-by: Caroline Tice <cmtice@google.com>
Reviewed-by: Han Shen <shenhan@google.com>
Diffstat (limited to 'crosperf/results_report.py')
-rw-r--r-- | crosperf/results_report.py | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/crosperf/results_report.py b/crosperf/results_report.py index f1b71810..4c7bd085 100644 --- a/crosperf/results_report.py +++ b/crosperf/results_report.py @@ -568,7 +568,8 @@ class JSONResultsReport(ResultsReport): super(JSONResultsReport, self).__init__(experiment) self.ro = ResultOrganizer(experiment.benchmark_runs, experiment.labels, - experiment.benchmarks) + experiment.benchmarks, + json_report=True) self.date = date self.time = time self.defaults = TelemetryDefaults() @@ -592,11 +593,18 @@ class JSONResultsReport(ResultsReport): json_results['date'] = self.date json_results['time'] = self.time json_results['board'] = board + json_results['label'] = label + common_checksum = '' + common_string = '' for l in self.experiment.labels: if l.name == label: ver, img = ParseChromeosImage(l.chromeos_image) json_results['chromeos_image'] = img json_results['chromeos_version'] = ver + common_checksum = \ + self.experiment.machine_manager.machine_checksum[l.name] + common_string = \ + self.experiment.machine_manager.machine_checksum_string[l.name] break json_results['test_name'] = test if not iter_results or iter_results['retval'] != 0: @@ -622,7 +630,14 @@ class JSONResultsReport(ResultsReport): if type(v) == list: v = v[0] if v != 'PASS': - detail_results[k] = float(v) + if k.find('machine') == -1: + detail_results[k] = float(v) + else: + json_results[k] = v + if 'machine_checksum' not in json_results.keys(): + json_results['machine_checksum'] = common_checksum + if 'machine_string' not in json_results.keys(): + json_results['machine_string'] = common_string json_results['detailed_results'] = detail_results final_results.append(json_results) |