diff options
author | David Lord <davidism@gmail.com> | 2023-04-28 09:43:59 -0700 |
---|---|---|
committer | David Lord <davidism@gmail.com> | 2023-04-28 09:43:59 -0700 |
commit | a83b56a8b1d728ac78eda0e14fee4ea2ba1cf45c (patch) | |
tree | 73446240e5365b1db6ea296ac5173b6abbec0543 | |
parent | 447d4a8046c787a641c34aa9cdeedabc21b180e2 (diff) | |
download | werkzeug-a83b56a8b1d728ac78eda0e14fee4ea2ba1cf45c.tar.gz |
update changelogs in docstrings
-rw-r--r-- | src/werkzeug/http.py | 5 | ||||
-rw-r--r-- | src/werkzeug/wrappers/request.py | 6 | ||||
-rw-r--r-- | src/werkzeug/wsgi.py | 4 |
3 files changed, 10 insertions, 5 deletions
diff --git a/src/werkzeug/http.py b/src/werkzeug/http.py index a2075c70..7edd1d3b 100644 --- a/src/werkzeug/http.py +++ b/src/werkzeug/http.py @@ -1388,9 +1388,12 @@ def dump_cookie( .. _`cookie`: http://browsercookielimits.squawky.net/ - .. versionchanged:: 2.3.1 + .. versionchanged:: 2.3.2 The ``path`` parameter is ``/`` by default. + .. versionchanged:: 2.3.1 + The value allows more characters without quoting. + .. versionchanged:: 2.3 ``localhost`` and other names without a dot are allowed for the domain. A leading dot is ignored. diff --git a/src/werkzeug/wrappers/request.py b/src/werkzeug/wrappers/request.py index 1ed7f77d..1788b538 100644 --- a/src/werkzeug/wrappers/request.py +++ b/src/werkzeug/wrappers/request.py @@ -330,10 +330,8 @@ class Request(_SansIORequest): Unlike :attr:`input_stream`, this stream guards against infinite streams or reading past :attr:`content_length` or :attr:`max_content_length`. - If :attr:`max_content_length` is set and the request has a - :attr:`content_length` (is not a streaming request), this will raise - :exc:`.RequestEntityTooLarge` if the max length is exceeded. Otherwise, the - limit will be checked during reads. + If ``max_content_length`` is set, it can be enforced on streams if + ``wsgi.input_terminated`` is set. Otherwise, an empty stream is returned. If the limit is reached before the underlying stream is exhausted (such as a file that is too large, or an infinite stream), the remaining contents of the diff --git a/src/werkzeug/wsgi.py b/src/werkzeug/wsgi.py index 8c50ecdd..a3a2fbb5 100644 --- a/src/werkzeug/wsgi.py +++ b/src/werkzeug/wsgi.py @@ -162,6 +162,10 @@ def get_input_stream( :param max_content_length: The maximum length that content-length or streaming requests may not exceed. + .. versionchanged:: 2.3.2 + ``max_content_length`` is only applied to streaming requests if the server sets + ``wsgi.input_terminated``. + .. versionchanged:: 2.3 Check ``max_content_length`` and raise an error if it is exceeded. |