We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Header Content-Length is ignored in web.Response constructor. It is set to 0 when body parameter is not passed to constructor.
Either to get warning like "your header was ignored" or to have it not ignored.
Header value is silently updated.
>>> headers = {'Content-Length':555} >>> r = web.Response(headers=headers) >>> r.headers <CIMultiDict('Content-Type': 'application/octet-stream', 'Content-Length': '0')>
aiohttp (1.1.3) Python 3.5.2 (v3.5.2:4def2a2901a5, Jun 25 2016, 22:18:55) [MSC v.1900 64 bit (AMD64)] on win32 Win10
The text was updated successfully, but these errors were encountered:
What is use case for providing Content-Length without BODY?
Content-Length
Sorry, something went wrong.
Respond to HEAD request. The HEAD method is identical to GET except that the server MUST NOT return a message-body in the response.
The HEAD method is identical to GET except that the server MUST NOT return a message-body in the response.
Good point, thank for report.
6fb5c7c
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
If you feel like there's important points made in this discussion, please include those exceprts into that new issue.
No branches or pull requests
Long story short
Header Content-Length is ignored in web.Response constructor.
It is set to 0 when body parameter is not passed to constructor.
Expected behaviour
Either to get warning like "your header was ignored" or to have it not ignored.
Actual behaviour
Header value is silently updated.
Steps to reproduce
Your environment
aiohttp (1.1.3)
Python 3.5.2 (v3.5.2:4def2a2901a5, Jun 25 2016, 22:18:55) [MSC v.1900 64 bit (AMD64)] on win32
Win10
The text was updated successfully, but these errors were encountered: