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

Unified Diff: appengine/findit/model/wf_suspected_cl.py

Issue 2425853005: [Findit] Modify Findit API to return more information to Sheriff-O-Matic. (Closed)
Patch Set: rebase Created 4 years, 2 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 | « appengine/findit/model/test/wf_suspected_cl_test.py ('k') | appengine/findit/test/findit_api_test.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: appengine/findit/model/wf_suspected_cl.py
diff --git a/appengine/findit/model/wf_suspected_cl.py b/appengine/findit/model/wf_suspected_cl.py
index 6df6187ba6f4c0bdde50fbe82106f1bc78669009..41ee6dbe291125e0c462f8b1a2ef014c1d3ffdd3 100644
--- a/appengine/findit/model/wf_suspected_cl.py
+++ b/appengine/findit/model/wf_suspected_cl.py
@@ -4,6 +4,7 @@
from google.appengine.ext import ndb
+from model.base_build_model import BaseBuildModel
from model.base_suspected_cl import BaseSuspectedCL
@@ -16,48 +17,40 @@ class WfSuspectedCL(BaseSuspectedCL):
# The dict of builds in which the suspected CL caused some breakage.
# The dict will look like:
# {
- # 'm1/b1/123': [
- # {
- # 'failure_type': 'compile',
- # 'failures': None,
- # 'status': CORRECT,
- # 'approaches': [HEURISTIC, TRY_JOB],
- # 'top_score': 5,
- # 'Confidence': 97.9
- # }
- # ],
- # 'm2/b2/234': [
- # {
- # 'failure_type': 'test',
- # 'failures': {
- # 's1': ['t1', 't2']
- # },
- # 'status': CORRECT,
- # 'approachES': [HEURISTIC, TRY_JOB],
- # 'top_score': None,
- # 'Confidence': 80.0
+ # 'm1/b1/123': {
+ # 'failure_type': 'compile',
+ # 'failures': None,
+ # 'status': CORRECT,
+ # 'approaches': [HEURISTIC, TRY_JOB],
+ # 'top_score': 5
+ # },
+ # 'm2/b2/234': {
+ # 'failure_type': 'test',
+ # 'failures': {
+ # 's1': ['t1', 't2']
# },
- # {
- # 'failure_type': 'test',
- # 'failures': {
- # 's1': ['t3']
- # },
- # 'status': INCORRECT,
- # 'approaches': [HEURISTIC],
- # 'top_score': 2,
- # 'Confidence': 50.5
+ # 'status': CORRECT,
+ # 'approachES': [HEURISTIC, TRY_JOB],
+ # 'top_score': None
+ # },
+ # {
+ # 'failure_type': 'test',
+ # 'failures': {
+ # 's1': ['t3']
# },
- # {
- # 'failure_type': 'test',
- # 'failures': {
- # 's2': []
- # },
- # 'status': INCORRECT,
- # 'approaches': [HEURISTIC],
- # 'top_score': 1,
- # 'Confidence': 30.7
- # }
- # ]
+ # 'status': INCORRECT,
+ # 'approaches': [HEURISTIC],
+ # 'top_score': 2
+ # },
+ # {
+ # 'failure_type': 'test',
+ # 'failures': {
+ # 's2': []
+ # },
+ # 'status': INCORRECT,
+ # 'approaches': [HEURISTIC],
+ # 'top_score': 1
+ # }
# }
builds = ndb.JsonProperty(indexed=False, compressed=True)
@@ -85,3 +78,8 @@ class WfSuspectedCL(BaseSuspectedCL):
instance.commit_position = commit_position
instance.builds = {}
return instance
+
+ def GetBuildInfo(self, master_name, builder_name, build_number):
+ build_key = BaseBuildModel.CreateBuildId(
+ master_name, builder_name, build_number)
+ return self.builds.get(build_key)
« no previous file with comments | « appengine/findit/model/test/wf_suspected_cl_test.py ('k') | appengine/findit/test/findit_api_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698