From 63e6cd1bb3edccb4db1eb6a79153fa31d2114cd4 Mon Sep 17 00:00:00 2001 From: Tim Graham Date: Fri, 23 Nov 2012 07:00:08 -0500 Subject: [PATCH] Fixed #19348 - Clarified the units of filesizeformat. Thanks george_edison for the report and Claude Paroz for the patch. --- docs/ref/templates/builtins.txt | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/ref/templates/builtins.txt b/docs/ref/templates/builtins.txt index 6e5e18543c..ba43e2eb15 100644 --- a/docs/ref/templates/builtins.txt +++ b/docs/ref/templates/builtins.txt @@ -1456,6 +1456,14 @@ For example:: If ``value`` is 123456789, the output would be ``117.7 MB``. +.. admonition:: File sizes and SI units + + Strictly speaking, ``filesizeformat`` does not conform to the International + System of Units which recommends using KiB, MiB, GiB, etc. when byte sizes + are calculated in powers of 1024 (which is the case here). Instead, Django + uses traditional unit names (KB, MB, GB, etc.) corresponding to names that + are more commonly used. + .. templatefilter:: first first