Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(260)

Unified Diff: log_parser/process_log.py

Issue 200137: Reference perf_id only if set.... (Closed) Base URL: svn://chrome-svn.corp.google.com/chrome/trunk/tools/buildbot/scripts/master/
Patch Set: Created 11 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: log_parser/process_log.py
===================================================================
--- log_parser/process_log.py (revision 26256)
+++ log_parser/process_log.py (working copy)
@@ -119,8 +119,7 @@
# Performance regression/speedup alerts.
self._perf_id = perf_id
self._perf_name = perf_name
- self._perf_filename = os.path.join(PERF_EXPECTATIONS_PATH,
- self._perf_id + ".json")
+ self._perf_filename = None
self._actual_performance = {}
self._expected_performance = {}
self._perf_regress = []
@@ -152,7 +151,11 @@
self._expected_performance[graph_name][result_type] = perf_data[perf_key]
def LoadPerformanceExpectations(self):
- self._expected = {}
+ if not self._perf_id:
+ logging.error("not loading perf expectations: perf_id missing")
Nicolas Sylvain 2009/09/15 21:47:47 is this really an error?
+ return
+ self._perf_filename = os.path.join(PERF_EXPECTATIONS_PATH,
+ self._perf_id + ".json")
try:
perf_file = open(self._perf_filename, 'r')
except IOError, e:
@@ -172,7 +175,7 @@
if perf_data and perf_data.has_key('load') and perf_data['load']:
self.LoadPerformanceExpectationsGroup(perf_data)
else:
- logging.error("not loading perf expectations, perf_data is disabled")
+ logging.error("not loading perf expectations: perf_data is disabled")
def TrackActualPerformance(self, graph_name=None, result_type=None,
value=None, stddev=None):
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698