From f31e7e8c2ac52f220b3485d8280b8121a20a5e18 Mon Sep 17 00:00:00 2001 From: "vadimsh@chromium.org" Date: Tue, 7 Apr 2015 22:44:08 +0000 Subject: [PATCH] Remove 'email', 'password' and 'private_key_file' properties of Rietveld class. They were used by CQ code, but CQ forked relevant parts of depot_tools already and no longer uses this code. These properties are unused now (as far as I can tell searching through code). They expose auth implementation details that better to be hidden (since they will change with OAuth2 adoption). R=maruel@chromium.org BUG=356813 Review URL: https://codereview.chromium.org/1063263002 git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@294707 0039d316-1c4b-4281-b951-d872f2087c98 --- rietveld.py | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/rietveld.py b/rietveld.py index e36d2cd3a..f3bcd718d 100644 --- a/rietveld.py +++ b/rietveld.py @@ -39,9 +39,7 @@ class Rietveld(object): """Accesses rietveld.""" def __init__(self, url, email, password, extra_headers=None, maxtries=None): self.url = url.rstrip('/') - # Email and password are accessed by commit queue, keep them. - self.email = email - self.password = password + # TODO(maruel): It's not awesome but maybe necessary to retrieve the value. # It happens when the presubmit check is ran out of process, the cookie # needed to be recreated from the credentials. Instead, it should pass the @@ -579,10 +577,6 @@ class JwtOAuth2Rietveld(Rietveld): extra_headers=None, maxtries=None): - # These attributes are accessed by commit queue. Keep them. - self.email = client_email - self.private_key_file = client_private_key_file - if private_key_password is None: # '' means 'empty password' private_key_password = 'notasecret' @@ -678,14 +672,6 @@ class ReadOnlyRietveld(object): def url(self): return self._rietveld.url - @property - def email(self): - return self._rietveld.email - - @property - def password(self): - return self._rietveld.password - def get_pending_issues(self): pending_issues = self._rietveld.get_pending_issues()