summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorTarek Ziade <tarek@ziade.org>2011-05-21 21:59:09 (GMT)
committerTarek Ziade <tarek@ziade.org>2011-05-21 21:59:09 (GMT)
commit2c40f60c32dbc97fc1c434e3501621902e46121f (patch)
treed7e48fbf003984078d073f2c059ce8770c321669 /Lib
parent99d4623850610b425a13384852711ff8fef2341d (diff)
downloadcpython-2c40f60c32dbc97fc1c434e3501621902e46121f.zip
cpython-2c40f60c32dbc97fc1c434e3501621902e46121f.tar.gz
cpython-2c40f60c32dbc97fc1c434e3501621902e46121f.tar.bz2
added the Content-Length header. that fixes the weird packaging.pypi.errors.HashDoesNotMatch errors
Diffstat (limited to 'Lib')
-rw-r--r--Lib/packaging/tests/pypi_server.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/Lib/packaging/tests/pypi_server.py b/Lib/packaging/tests/pypi_server.py
index 6a72afb..372a54c 100644
--- a/Lib/packaging/tests/pypi_server.py
+++ b/Lib/packaging/tests/pypi_server.py
@@ -226,6 +226,7 @@ class PyPIRequestHandler(SimpleHTTPRequestHandler):
data = file.read().encode()
headers = [('Content-type', 'text/html')]
+ headers.append(('Content-Length', len(data)))
self.make_response(data, headers=headers)
except IOError: