Fixes python-swiftclient debugging message
Appends the container's name to the URL displayed, to be used to replay the queries with curl. Replaying the curl commands displayed by "swift --debug list <container>" now works properly. Example: $ swift --debug list test-container ... DEBUG:swiftclient:REQ: curl -i http://10.0.48.134:8080/v1/AUTH_6c554b8dd3d74e44878eddb92caf8687/test-container?format=json -X GET -H ... ... Change-Id: I7ec33d185fedc44a529c016d38f841fde39d20d0 Closes-Bug: #1238612
This commit is contained in:
parent
1aa85960fd
commit
c81a9edd1f
@ -528,7 +528,8 @@ def get_container(url, token, container, marker=None, limit=None,
|
||||
conn.request(method, '%s?%s' % (cont_path, qs), '', headers)
|
||||
resp = conn.getresponse()
|
||||
body = resp.read()
|
||||
http_log(('%s?%s' % (url, qs), method,), {'headers': headers}, resp, body)
|
||||
http_log(('%s%s?%s' % (url.replace(parsed.path, ''), cont_path, qs),
|
||||
method,), {'headers': headers}, resp, body)
|
||||
|
||||
if resp.status < 200 or resp.status >= 300:
|
||||
raise ClientException('Container GET failed',
|
||||
|
Loading…
x
Reference in New Issue
Block a user