summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorAndrew Svetlov <andrew.svetlov@gmail.com>2012-11-27 21:06:19 (GMT)
committerAndrew Svetlov <andrew.svetlov@gmail.com>2012-11-27 21:06:19 (GMT)
commitbff98fe5364452775d8273137c9087ed004deb96 (patch)
tree239c649e4b032a060a1d3d36c66097ca896cf4d6 /Doc
parent9a270d9741f755d2114bc363a2be48135ec67870 (diff)
downloadcpython-bff98fe5364452775d8273137c9087ed004deb96.zip
cpython-bff98fe5364452775d8273137c9087ed004deb96.tar.gz
cpython-bff98fe5364452775d8273137c9087ed004deb96.tar.bz2
Issue #16464: reset Request's Content-Length header on .data change.
It will be recalculated on sending request to HTTP server. Patch by Alexey Kachayev
Diffstat (limited to 'Doc')
-rw-r--r--Doc/library/urllib.request.rst10
1 files changed, 10 insertions, 0 deletions
diff --git a/Doc/library/urllib.request.rst b/Doc/library/urllib.request.rst
index 84c387c..65637fd 100644
--- a/Doc/library/urllib.request.rst
+++ b/Doc/library/urllib.request.rst
@@ -408,6 +408,10 @@ request.
The entity body for the request, or None if not specified.
+ .. versionchanged:: 3.4
+ Changing value of :attr:`Request.data` now deletes "Content-Length"
+ header if it was previously set or calculated.
+
.. attribute:: Request.unverifiable
boolean, indicates whether the request is unverifiable as defined
@@ -456,6 +460,12 @@ request.
unredirected).
+.. method:: Request.remove_header(header)
+
+ Remove named header from the request instance (both from regular and
+ unredirected headers).
+
+
.. method:: Request.get_full_url()
Return the URL given in the constructor.