Skip to content
Browse files

Fixed #16392 -- Clarified docs of the "c" date format with regard to …

…naive datetime objects. Thanks, ybon.

git-svn-id: bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
1 parent cb2d8cd commit 8066fced3398405c5c2153ca33b3441ef7e1b2dc @jezdez jezdez committed
Showing with 6 additions and 1 deletion.
  1. +6 −1 docs/ref/templates/builtins.txt
7 docs/ref/templates/builtins.txt
@@ -1251,7 +1251,10 @@ Available format strings:
A ``'AM'`` or ``'PM'``. ``'AM'``
b Month, textual, 3 letters, lowercase. ``'jan'``
B Not implemented.
- c ISO 8601 Format. ``2008-01-02T10:30:00.000123``
+ c ISO 8601 format. (Note: unlike others ``2008-01-02T10:30:00.000123+02:00``,
+ formatters, such as "Z", "O" or "r", or ``2008-01-02T10:30:00.000123`` if the datetime is naive
+ the "c" formatter will not add timezone
+ offset if value is a `naive datetime`_.)
d Day of the month, 2 digits with ``'01'`` to ``'31'``
leading zeros.
D Day of the week, textual, 3 letters. ``'Fri'``
@@ -1343,6 +1346,8 @@ used, without applying any localization.
.. versionchanged:: 1.2
Predefined formats can now be influenced by the current locale.
+.. _naive datetime:
.. templatefilter:: default

0 comments on commit 8066fce

Please sign in to comment.
Something went wrong with that request. Please try again.