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

Unified Diff: appengine/findit/common/rietveld.py

Issue 2344443005: [Findit] Factoring the gitiles (etc) stuff out into its own directory (Closed)
Patch Set: reverted unintended change to an __init__ file 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/common/rietveld.py
diff --git a/appengine/findit/common/rietveld.py b/appengine/findit/common/rietveld.py
index fab452cbd107029c3f3be7d7ac718975a4d3200a..c7b3a6584497bbfaaf724ef4d88592522d1f97ae 100644
--- a/appengine/findit/common/rietveld.py
+++ b/appengine/findit/common/rietveld.py
@@ -2,18 +2,27 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
+# TODO: In the new layout, this should move to the ./services or
+# ./services/waterfall_app directories, since it is only used by Waterfall.
+
+# TODO: we ought to abstract over the HTTP_CLIENT member (which is only
+# used by the Post method) by passing it to the constructor. That way
+# things are more losely coupled, improving modularity and reducing
+# fragility. In addition, for easier mocking, we may want to just have
+# the thing passed for HTTP_CLIENT to be ``callable``, rather than giving
+# a name to the method we use on that object.
+
import logging
import re
import urlparse
-from common.codereview import CodeReview
from common.http_client_appengine import HttpClientAppengine
_RIETVELD_ISSUE_NUMBER_RE = re.compile('^/(\d+)/?.*')
-class Rietveld(CodeReview):
+class Rietveld(object):
"""The implementation of CodeReview interface for Rietveld."""
HTTP_CLIENT = HttpClientAppengine(follow_redirects=False)

Powered by Google App Engine
This is Rietveld 408576698