Merged revisions 71037 via svnmerge from

svn+ssh://pythondev@svn.python.org/python/trunk

........
  r71037 | r.david.murray | 2009-04-02 00:34:04 -0400 (Thu, 02 Apr 2009) | 6 lines

  Clarify that datetime strftime does not produce leap seconds and datetime
  strptime does not accept it in the strftime behavior section of the
  datetime docs.

  Closes issue 2568.
........
This commit is contained in:
R. David Murray 2009-04-02 04:52:48 +00:00
parent 945e052acc
commit dc362b0b96
1 changed files with 6 additions and 2 deletions

View File

@ -1629,8 +1629,12 @@ Notes:
the output hour field if the ``%I`` directive is used to parse the hour. the output hour field if the ``%I`` directive is used to parse the hour.
(3) (3)
The range really is ``0`` to ``61``; this accounts for leap seconds and the The range really is ``0`` to ``61``; according to the Posix standard this
(very rare) double leap seconds. accounts for leap seconds and the (very rare) double leap seconds.
The :mod:`time` module may produce and does accept leap seconds since
it is based on the Posix standard, but the :mod:`datetime` module
does not accept leap seconds in :func:`strptime` input nor will it
produce them in :func:`strftime` output.
(4) (4)
When used with the :func:`strptime` function, ``%U`` and ``%W`` are only used in When used with the :func:`strptime` function, ``%U`` and ``%W`` are only used in