Skip to content

Commit a6f10ca

Browse files
committed
Closes python#28130: Documented that time.tzset() updates time module globals.
Thanks Greg Bengeult for the patch.
1 parent 99ba17f commit a6f10ca

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

Doc/library/time.rst

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -464,8 +464,13 @@ The module defines the following functions and data items:
464464

465465
.. function:: tzset()
466466

467-
Resets the time conversion rules used by the library routines. The environment
468-
variable :envvar:`TZ` specifies how this is done.
467+
Reset the time conversion rules used by the library routines. The environment
468+
variable :envvar:`TZ` specifies how this is done. It will also set the variables
469+
``tzname`` (from the :envvar:`TZ` environment variable), ``timezone`` (non-DST
470+
seconds West of UTC), ``altzone`` (DST seconds west of UTC) and ``daylight``
471+
(to 0 if this timezone does not have any daylight saving time rules, or to
472+
nonzero if there is a time, past, present or future when daylight saving time
473+
applies).
469474

470475
.. versionadded:: 2.3
471476

0 commit comments

Comments
 (0)