diff options
author | Alexerson <Alexerson@users.noreply.github.com> | 2023-05-12 06:34:47 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-12 10:34:47 -0300 |
commit | 599f3e2cda50ab084915ffd08edb5ad6cad61415 (patch) | |
tree | 9078b89144462ffc3f52644b4fd9464853678ec9 | |
parent | e901407e2369ddb16a5c866e1f2fbf8ea8acf549 (diff) | |
download | django-599f3e2cda50ab084915ffd08edb5ad6cad61415.tar.gz |
Fixed #34556 -- Doc'd that StreamingHttpResponse accepts memoryviews and strings iterators.
-rw-r--r-- | docs/ref/request-response.txt | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/docs/ref/request-response.txt b/docs/ref/request-response.txt index 37f3180ddc..e70dae4de7 100644 --- a/docs/ref/request-response.txt +++ b/docs/ref/request-response.txt @@ -1213,9 +1213,9 @@ The :class:`StreamingHttpResponse` is not a subclass of :class:`HttpResponse`, because it features a slightly different API. However, it is almost identical, with the following notable differences: -* It should be given an iterator that yields bytestrings as content. When - serving under WSGI, this should be a sync iterator. When serving under ASGI, - this is should an async iterator. +* It should be given an iterator that yields bytestrings, :class:`memoryview`, + or strings as content. When serving under WSGI, this should be a sync + iterator. When serving under ASGI, then it should be an async iterator. * You cannot access its content, except by iterating the response object itself. This should only occur when the response is returned to the client: |