aboutsummaryrefslogtreecommitdiff
path: root/Lib/http
diff options
context:
space:
mode:
authorMarco Strigl <mstrigl@suse.com>2018-06-19 15:20:58 +0200
committerSerhiy Storchaka <storchaka@gmail.com>2018-06-19 16:20:58 +0300
commit936f03e7fafc28fd6fdfba11d162c776b89c0167 (patch)
treed6b0e312d49674aed7bde34ce2674ffe343e10fc /Lib/http
parentbpo-33901: Fix test_dbm_gnu for gdbm 1.15 (GH-7791) (diff)
downloadcpython-936f03e7fafc28fd6fdfba11d162c776b89c0167.tar.gz
cpython-936f03e7fafc28fd6fdfba11d162c776b89c0167.tar.bz2
cpython-936f03e7fafc28fd6fdfba11d162c776b89c0167.zip
bpo-33365: print the header values beside the keys (GH-6611)
with debuglevel=1 only the header keys got printed. With this change the header values get printed as well and the single header entries get '\n' as a separator.
Diffstat (limited to 'Lib/http')
-rw-r--r--Lib/http/client.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/http/client.py b/Lib/http/client.py
index 1292db74784..5aa178d7b12 100644
--- a/Lib/http/client.py
+++ b/Lib/http/client.py
@@ -321,7 +321,7 @@ class HTTPResponse(io.BufferedIOBase):
if self.debuglevel > 0:
for hdr in self.headers:
- print("header:", hdr, end=" ")
+ print("header:", hdr + ":", self.headers.get(hdr))
# are we using the chunked-style of transfer encoding?
tr_enc = self.headers.get("transfer-encoding")