httpclient: remove unused debug kwargs

This has been deprecated for a while and is now not even used anymore.

Indeed, nothing in the code use the attribute
keystoneclient.httpclient.HTTPClient.debug_log.
Furthermore, removing the debug keyword argument from the signature of
keystoneclient.httpclient.HTTPClient.__init__ has no impact since this
signature include **kwargs, which in Python means that you it will
accept any keyword-argument. Any code that would still pass the debug
argument to that method will therefore not notice any difference and
will not fail.

Change-Id: Iaae4febf3f13f6a66ad0e792dc2347b4699f65c0
This commit is contained in:
Julien Danjou
2015-10-18 21:55:51 +02:00
parent a4ca83b840
commit 14900dd683
2 changed files with 1 additions and 6 deletions

View File

@@ -196,9 +196,6 @@ class HTTPClient(baseclient.Client, base.BaseAuthPlugin):
:param string original_ip: This argument is deprecated as of the 1.7.0
release in favor of session and may be removed
in the 2.0.0 release. (optional)
:param boolean debug: This argument is deprecated as of the 1.7.0 release
in favor of logging configuration and may be removed
in the 2.0.0 release. (optional)
:param dict auth_ref: To allow for consumers of the client to manage their
own caching strategy, you may initialize a client
with a previously captured auth_reference (token). If
@@ -249,7 +246,7 @@ class HTTPClient(baseclient.Client, base.BaseAuthPlugin):
@positional(enforcement=positional.WARN)
def __init__(self, username=None, tenant_id=None, tenant_name=None,
password=None, auth_url=None, region_name=None, endpoint=None,
token=None, debug=False, auth_ref=None, use_keyring=False,
token=None, auth_ref=None, use_keyring=False,
force_new_token=False, stale_duration=None, user_id=None,
user_domain_id=None, user_domain_name=None, domain_id=None,
domain_name=None, project_id=None, project_name=None,
@@ -378,7 +375,6 @@ class HTTPClient(baseclient.Client, base.BaseAuthPlugin):
self.session = session
self.domain = ''
self.debug_log = debug
# NOTE(jamielennox): unfortunately we can't just use **kwargs here as
# it would incompatibly limit the kwargs that can be passed to __init__

View File

@@ -499,7 +499,6 @@ class ClientDiscoveryTests(utils.TestCase):
client = disc.create_client(debug=True, password='bar')
self.assertIsInstance(client, v3_client.Client)
self.assertTrue(client.debug_log)
self.assertFalse(disc._client_kwargs['debug'])
self.assertEqual(client.username, 'foo')
self.assertEqual(client.password, 'bar')