Martin Panter <vadmium...@gmail.com> added the comment:

Thanks, although the fact that “Content-Length: 0” doesn’t work kills my theory 
about the proxy.

The “close_connection” flag is also a documented public API of Python: 
<https://docs.python.org/3/library/http.server.html#http.server.BaseHTTPRequestHandler.close_connection>.
 According to the rules for framing the message body in 
<https://tools.ietf.org/html/rfc7230#section-3.3.3>, the presence of 
“Connection: close” is not important. The server actually shutting down the 
connection is the key. That is why I prefer to explicitly set the flag (if it 
works).

Anyway, your current proposal makes the server send a valid full HTTP response.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue25095>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to