mirror of
https://github.com/python/cpython.git
synced 2025-11-25 04:34:37 +00:00
added the Content-Length header. that fixes the weird packaging.pypi.errors.HashDoesNotMatch errors
This commit is contained in:
parent
99d4623850
commit
2c40f60c32
1 changed files with 1 additions and 0 deletions
|
|
@ -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…
Add table
Add a link
Reference in a new issue