/external/chromium-trace/catapult/dashboard/dashboard/models/ |
sheriff_test.py | 8 from dashboard.models import sheriff namespace 14 with self.assertRaises(sheriff.ValidationError): 15 sheriff.Sheriff(url='oops') 17 with self.assertRaises(sheriff.ValidationError): 18 sheriff.Sheriff(url='x.com') 19 with self.assertRaises(sheriff.ValidationError): 20 sheriff.Sheriff(url='http://x.com' [all...] |
alert_group.py | 151 sheriff = anomaly_entity.test.get().sheriff 152 if not sheriff: 155 sheriff = sheriff.string_id() 162 logger = quick_logger.QuickLogger('auto_triage', sheriff, formatter)
|
stoppage_alert_test.py | 10 from dashboard.models import sheriff namespace 19 sheriff.Sheriff(id='Foo', patterns=['*/*/*/*']).put() 32 self.assertEqual(test.sheriff, alert.sheriff)
|
stoppage_alert.py | 99 sheriff=test.sheriff)
|
graph_data.py | 67 from dashboard.models import sheriff as sheriff_module 119 # Sheriff rotation for this test. Rotations are specified by regular 121 sheriff = ndb.KeyProperty(kind=sheriff_module.Sheriff, indexed=True) variable in class:Test 159 # for alerts (i.e. they have a sheriff). For other tests, this is empty. 262 # Set the sheriff to the first sheriff (alphabetically by sheriff name) 264 self.sheriff = None 265 for sheriff_entity in sheriff_module.Sheriff.query().fetch() [all...] |
/external/chromium-trace/catapult/dashboard/dashboard/ |
list_monitored_tests.py | 16 """An endpoint to list the tests monitored by a given sheriff.""" 19 """Returns a JSON list of tests for a sheriff. 22 get-sheriffed-by: A sheriff name. 24 sheriff = self.request.get('get-sheriffed-by') 25 if not sheriff: 28 self.response.out.write(json.dumps(_ListMonitoredTests(sheriff))) 33 sheriff = ndb.Key('Sheriff', sheriff_name) 35 graph_data.Test.sheriff == sheriff, [all...] |
email_sheriff.py | 5 """Provides a function for emailing an alert to a sheriff on duty.""" 14 def EmailSheriff(sheriff, test, anomaly): 15 """Sends an email to the sheriff on duty about the given anomaly. 18 sheriff: sheriff.Sheriff entity. 22 receivers = email_template.GetSheriffEmails(sheriff) 24 logging.warn('No email address for %s', sheriff)
|
edit_sheriffs_test.py | 19 from dashboard.models import sheriff namespace 48 """Adds a Sheriff entity to the datastore.""" 49 sheriff.Sheriff( 57 'add-name': 'New Sheriff', 63 sheriffs = sheriff.Sheriff.query().fetch() 65 self.assertEqual('New Sheriff', sheriffs[0].key.string_id()) 73 self._AddSheriff('Old Sheriff') 76 'edit-name': 'Old Sheriff', [all...] |
edit_sheriffs.py | 5 """Provides the web interface for adding and editing sheriff rotations.""" 10 from dashboard.models import sheriff namespace 14 """Handles editing of Sheriff entities. 18 are properties of Sheriff: 27 request, response, sheriff.Sheriff) 42 for entity in sheriff.Sheriff.query()} 50 """Updates the given Sheriff based on query parameters. 53 sheriff_entity: A Sheriff entity [all...] |
auto_triage_test.py | 18 from dashboard.models import sheriff namespace 36 sheriff_key: A Sheriff entity key. 46 test.sheriff = sheriff_key 69 sheriff=sheriff_key).put() 72 sheriff_key = sheriff.Sheriff(email='a@google.com', id='sheriff_key').put() 85 sheriff_key = sheriff.Sheriff(email='a@google.com', id='sheriff_key').put() 98 sheriff_key = sheriff.Sheriff(email='a@google.com', id='sheriff_key').put( [all...] |
email_template.py | 53 'labels=Type-Bug-Regression,Pri-2,Performance-Sheriff,%s') 56 '<a href="https://chromeperf.appspot.com/alerts?sheriff=%s">' 185 def GetSheriffEmails(sheriff): 186 """Gets all of the email addresses to send mail to for a Sheriff. 188 This includes both the general email address of the sheriff rotation, 190 sheriff on duty, if applicable. 193 sheriff: A Sheriff entity. 199 receivers = [sheriff.email] if sheriff.email else [ [all...] |
dump_graph_json.py | 33 if self.request.get('sheriff'): 51 Test, Row, Anomaly and Sheriff entities). 71 # Get the Anomaly and Sheriff entities. 74 sheriff_keys = {alert.sheriff for alert in alerts} 75 sheriffs = [sheriff.get() for sheriff in sheriff_keys] 87 sheriff: Sheriff name. 94 Test, Row, Anomaly and Sheriff entities). 96 sheriff_name = self.request.get('sheriff') [all...] |
bench_find_anomalies_test.py | 20 from dashboard.models import sheriff namespace 38 self.sheriff = sheriff.Sheriff( 55 sheriff_entity = self.sheriff.get() 91 sheriff=self.sheriff).put()
|
email_summary.py | 15 from dashboard.models import sheriff namespace 27 """Summarizes alerts and sends e-mail to sheriff on duty. 30 anomalies related to that sheriff that were triggered in the past 24 hours. 37 sheriffs_to_email_query = sheriff.Sheriff.query( 38 sheriff.Sheriff.summarize == True) 48 """Sends a summary email for the given sheriff rotation. 51 sheriff_entity: A Sheriff entity. 66 """Returns untriaged anomalies for |sheriff| after |start_time|."" [all...] |
send_stoppage_alert_emails.py | 15 from dashboard.models import sheriff namespace 56 '?labels=Pri-1,Performance-Waterfall,Performance-Sheriff,' 71 sheriffs_to_email_query = sheriff.Sheriff.query( 72 sheriff.Sheriff.stoppage_alert_delay > 0) 78 """Sends a summary email for the given sheriff rotation. 81 sheriff_entity: A Sheriff key. 102 stoppage_alert.StoppageAlert.sheriff == sheriff_entity.key, 110 sheriff_entity: The Sheriff who will receive the alerts [all...] |
stats_test.py | 19 from dashboard.models import sheriff namespace 61 sheriff.Sheriff( 62 id='Chromium Perf Sheriff', 88 correct_sheriff = sheriff.Sheriff( 89 id='Chromium Perf Sheriff', patterns=[]).put() 90 wrong_sheriff = sheriff.Sheriff( 91 id='Some other sheriff', patterns=[]).put( [all...] |
email_summary_test.py | 17 from dashboard.models import sheriff namespace 45 timestamp=anomaly_time, sheriff=sheriff_key).put() 48 """Adds a sheriff with summarize set to False, and some alerts.""" 49 sheriff_key = sheriff.Sheriff( 50 id='Chromium Perf Sheriff', email='anandc@google.com', 64 sheriff_key = sheriff.Sheriff( 65 id='Chromium Perf Sheriff', email='anandc@google.com', 79 sheriff_key = sheriff.Sheriff [all...] |
find_anomalies.py | 54 sheriff = _GetSheriffForTest(test) 55 if not sheriff: 56 logging.error('No sheriff for %s', test_key) 78 # Email sheriff about any new regressions. 82 not sheriff.summarize): 83 email_sheriff.EmailSheriff(sheriff, test, anomaly_entity) 200 """Gets the Sheriff for a test, or None if no sheriff.""" 201 if test.sheriff: 202 return test.sheriff.get( [all...] |
main.py | 20 _DEFAULT_SHERIFF_NAME = 'Chromium Perf Sheriff' 31 sheriff: Sheriff to show anomalies for (optional) 39 sheriff_name = self.request.get('sheriff', _DEFAULT_SHERIFF_NAME) 40 sheriff = ndb.Key('Sheriff', sheriff_name) 42 anomalies = _GetRecentAnomalies(days, sheriff) 58 def _GetRecentAnomalies(days, sheriff): 63 sheriff: The ndb.Key of the Sheriff to fetch Anomalies for [all...] |
alerts_test.py | 17 from dashboard.models import sheriff namespace 34 sheriff_key = sheriff.Sheriff( 35 id='Chromium Perf Sheriff', email='sullivan@google.com').put() 62 sheriff=sheriff_key) 74 bug_id=bug_id, sheriff=sheriff_key) 87 sheriff=sheriff_key) 154 # Add another sheriff to the mock datastore, and set the sheriff of some 155 # anomalies to be this new sheriff [all...] |
dump_graph_json_test.py | 18 from dashboard.models import sheriff namespace 101 sheriff_key = sheriff.Sheriff(email='example@google.com').put() 102 anomaly.Anomaly(sheriff=sheriff_key, test=test_key).put() 113 sheriffs = _EntitiesOfKind(entities, 'Sheriff') 126 chromium_sheriff = sheriff.Sheriff( 127 id='Chromium Perf Sheriff', email='chrisphan@google.com').put() 128 qa_sheriff = sheriff.Sheriff( [all...] |
send_stoppage_alert_emails_test.py | 14 from dashboard.models import sheriff namespace 31 sheriff.Sheriff(
|
find_anomalies_test.py | 16 from dashboard.models import sheriff namespace 129 sheriff.Sheriff( 130 email='a@google.com', id='sheriff', patterns=[test_path]).put() 136 mock.call(ModelMatcher('sheriff'), 139 mock.call(ModelMatcher('sheriff'), 142 mock.call(ModelMatcher('sheriff'), 159 a.sheriff.string_id() == sheriff_name and 167 start_revision=10007, end_revision=10011, sheriff_name='sheriff', 173 start_revision=10037, end_revision=10041, sheriff_name='sheriff', [all...] |
associate_alerts_test.py | 20 from dashboard.models import sheriff namespace 35 """Adds a Sheriff and returns its key.""" 36 return sheriff.Sheriff( 37 id='Chromium Perf Sheriff', email='sullivan@google.com').put() 64 sheriff=sheriff_key).put() 71 sheriff=sheriff_key).put() 78 sheriff=sheriff_key, bug_id=12345).put()
|
list_monitored_tests_test.py | 14 from dashboard.models import sheriff namespace 39 """Adds a Sheriff entity to the datastore.""" 40 sheriff.Sheriff( 60 '/list_monitored_tests', {'get-sheriffed-by': 'Bogus Sheriff'})
|