mirror of https://github.com/python/cpython
added the Content-Length header. that fixes the weird packaging.pypi.errors.HashDoesNotMatch errors
This commit is contained in:
parent
99d4623850
commit
2c40f60c32
|
@ -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:
|
||||
|
|
Loading…
Reference in New Issue