From 1ba04810e99fd917454c2f354bd6e67e958b417f Mon Sep 17 00:00:00 2001 From: Chmouel Boudjnah Date: Sat, 9 Feb 2013 03:22:00 +0100 Subject: [PATCH] Fix debug with requests. - From http://docs.python.org/2/library/functions.html#hasattr : hasattr(object, name) -- The arguments are an object and a string. - Fixes bug 1124084. Change-Id: I47283abff440abdf827598c2497519f3de510baf --- keystoneclient/client.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/keystoneclient/client.py b/keystoneclient/client.py index 14c38b066..9b6f6ddfe 100644 --- a/keystoneclient/client.py +++ b/keystoneclient/client.py @@ -117,7 +117,7 @@ class HTTPClient(object): ch = logging.StreamHandler() _logger.setLevel(logging.DEBUG) _logger.addHandler(ch) - if hasattr(requests, logging): + if hasattr(requests, 'logging'): requests.logging.getLogger(requests.__name__).addHandler(ch) # keyring setup