Issue #25738: Don’t send message body for 205 Reset Content

Patch by Susumu Koshiba.
This commit is contained in:
Martin Panter 2016-06-08 08:29:13 +00:00
parent 4e50553823
commit e42e129ebe
5 changed files with 73 additions and 11 deletions

View file

@ -191,7 +191,9 @@ of which this module provides three different variants:
a complete set of headers, as the response body. The :attr:`responses`
attribute holds the default values for *message* and *explain* that
will be used if no value is provided; for unknown codes the default value
for both is the string ``???``.
for both is the string ``???``. The body will be empty if the method is
HEAD or the response code is one of the following: ``1xx``,
``204 No Content``, ``205 Reset Content``, ``304 Not Modified``.
.. versionchanged:: 3.4
The error response includes a Content-Length header.