From 2d7b864b1715f0569e37e3be55d6c6b0461c5cd5 Mon Sep 17 00:00:00 2001 From: haobing1 Date: Tue, 12 Jul 2016 21:11:05 +0800 Subject: [PATCH] Fix string interpolation to delayed to be handled by the logging code String interpolation should be delayed to be handled by the logging code, rather than being done at the point of the logging call. See the oslo i18n guideline. * http://docs.openstack.org/developer/oslo.i18n/guidelines.html Change-Id: If06663076e4081c6268ba88c157513723b734b31 Closes-Bug: #1596829 --- glanceclient/common/http.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/glanceclient/common/http.py b/glanceclient/common/http.py index 0eb42dec..2c211236 100644 --- a/glanceclient/common/http.py +++ b/glanceclient/common/http.py @@ -93,7 +93,7 @@ class _BaseHTTPClient(object): def _handle_response(self, resp): if not resp.ok: - LOG.debug("Request returned failure status %s." % resp.status_code) + LOG.debug("Request returned failure status %s.", resp.status_code) raise exc.from_response(resp, resp.content) elif (resp.status_code == requests.codes.MULTIPLE_CHOICES and resp.request.path_url != '/versions'):