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

Unified Diff: appengine/findit/handlers/flake/check_flake.py

Issue 2411893002: [Findit] Adding metadata for manually vs automatically triggered flake analyses (Closed)
Patch Set: Addressing comments 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/findit_api.py ('k') | appengine/findit/model/flake/master_flake_analysis.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: appengine/findit/handlers/flake/check_flake.py
diff --git a/appengine/findit/handlers/flake/check_flake.py b/appengine/findit/handlers/flake/check_flake.py
index 4e23f629df1cf44f2b2424c4509dc87b33da8bcf..2396879d8253d17d7b7f3a4aed1c3af72d5482ae 100644
--- a/appengine/findit/handlers/flake/check_flake.py
+++ b/appengine/findit/handlers/flake/check_flake.py
@@ -2,8 +2,6 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
-from google.appengine.api import users
-
from common import auth_util
from common import constants
from common import time_util
@@ -11,6 +9,7 @@ from common.base_handler import BaseHandler
from common.base_handler import Permission
from model import analysis_status
from waterfall.flake import initialize_flake_pipeline
+from waterfall.flake import triggering_sources
class CheckFlake(BaseHandler):
@@ -32,9 +31,12 @@ class CheckFlake(BaseHandler):
self.request.get('force') == '1')
allow_new_analysis = self.IsCorpUserOrAdmin()
+ # TODO(lijeffrey): Use flake_analysis_service.ScheduleAnalysisForFlake.
+ user_email = auth_util.GetUserEmail()
analysis = initialize_flake_pipeline.ScheduleAnalysisIfNeeded(
master_name, builder_name, build_number, step_name, test_name,
allow_new_analysis, force=force, manually_triggered=True,
+ user_email=user_email, triggering_source=triggering_sources.FINDIT_UI,
queue_name=constants.WATERFALL_ANALYSIS_QUEUE)
if not analysis: # pragma: no cover.
« no previous file with comments | « appengine/findit/findit_api.py ('k') | appengine/findit/model/flake/master_flake_analysis.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698