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

Unified Diff: dashboard/dashboard/services/gerrit_service.py

Issue 3019553002: [pinpoint] Gerrit patch support. (Closed)
Patch Set: Example URL Created 3 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
Index: dashboard/dashboard/services/gerrit_service.py
diff --git a/dashboard/dashboard/services/gerrit_service.py b/dashboard/dashboard/services/gerrit_service.py
new file mode 100644
index 0000000000000000000000000000000000000000..fcb3640f92625775141839b059d3dd7b3fd9174f
--- /dev/null
+++ b/dashboard/dashboard/services/gerrit_service.py
@@ -0,0 +1,15 @@
+# Copyright 2017 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.
+
+"""Functions for interfacing with Gerrit, a web-based code review tool for Git.
+
+API doc: https://gerrit-review.googlesource.com/Documentation/rest-api.html
+"""
+
+from dashboard.services import request
+
+
+def GetChange(server_url, change_id, fields=None):
+ url = '%s/changes/%s' % (server_url, change_id)
+ return request.RequestJson(url, o=fields)

Powered by Google App Engine
This is Rietveld 408576698