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

Unified Diff: appengine/findit/waterfall/flake/flake_analysis_service.py

Issue 2397603002: [Findit] Cloud Endpoints API to receive reports on flakes. (Closed)
Patch Set: 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
Index: appengine/findit/waterfall/flake/flake_analysis_service.py
diff --git a/appengine/findit/waterfall/flake/flake_analysis_service.py b/appengine/findit/waterfall/flake/flake_analysis_service.py
new file mode 100644
index 0000000000000000000000000000000000000000..ea36ab9f1533c0fd160327bd6f422fad786b8442
--- /dev/null
+++ b/appengine/findit/waterfall/flake/flake_analysis_service.py
@@ -0,0 +1,20 @@
+# Copyright 2016 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+
+def ScheduleAnalysisForFlake(
+ _request, _user_email, _is_admin): # pragma: no cover.
+ """Schedules an analysis on the flake in the given request if needed.
+
+ Args:
+ request (FlakeAnalysisRequest): The request to analyze a flake.
+ user_email (str): The email of the requester.
+ is_admin (bool): Whether the requester is an admin.
+
+ Returns:
+ An instance of MasterFlakeAnalysis if an analysis was scheduled; otherwise
+ None if no analysis was scheduled before and the user has no permission to.
+ """
+ # TODO (stgao): hook up with analysis.
+ return False

Powered by Google App Engine
This is Rietveld 408576698