From ad332e5ca9503bba2e14cc8c3ca675eed56d72bc Mon Sep 17 00:00:00 2001 From: Kevin Christopher Henry Date: Tue, 11 Oct 2016 03:42:00 -0400 Subject: Refs #19705 -- Made GZipMiddleware make ETags weak. Django's conditional request processing can now produce 304 Not Modified responses for content that is subject to compression. --- docs/ref/middleware.txt | 3 +++ 1 file changed, 3 insertions(+) (limited to 'docs/ref') diff --git a/docs/ref/middleware.txt b/docs/ref/middleware.txt index 432f5437ff..d007d252f5 100644 --- a/docs/ref/middleware.txt +++ b/docs/ref/middleware.txt @@ -155,6 +155,9 @@ It will NOT compress content if any of the following are true: * The request (the browser) hasn't sent an ``Accept-Encoding`` header containing ``gzip``. +If the response has an ``ETag`` header, the ETag is made weak to comply with +:rfc:`7232#section-2.1`. + You can apply GZip compression to individual views using the :func:`~django.views.decorators.gzip.gzip_page()` decorator. -- cgit v1.3