summaryrefslogtreecommitdiffstats
path: root/Doc/library/logging.handlers.rst
diff options
context:
space:
mode:
authorVinay Sajip <vinay_sajip@yahoo.co.uk>2016-07-22 17:23:04 (GMT)
committerVinay Sajip <vinay_sajip@yahoo.co.uk>2016-07-22 17:23:04 (GMT)
commit638e6220557db50b01653b410eb12f11b9b8ab1c (patch)
treeb685830fe324decdb9c7a5dc68abb31ccd32c617 /Doc/library/logging.handlers.rst
parentd3afb62b8fb38417c3f0bf6873ed64bd9efd8e43 (diff)
downloadcpython-638e6220557db50b01653b410eb12f11b9b8ab1c.zip
cpython-638e6220557db50b01653b410eb12f11b9b8ab1c.tar.gz
cpython-638e6220557db50b01653b410eb12f11b9b8ab1c.tar.bz2
Closes #27493: accepted Path objects in file handlers for logging.
Diffstat (limited to 'Doc/library/logging.handlers.rst')
-rw-r--r--Doc/library/logging.handlers.rst13
1 files changed, 13 insertions, 0 deletions
diff --git a/Doc/library/logging.handlers.rst b/Doc/library/logging.handlers.rst
index 266a500..748eb31 100644
--- a/Doc/library/logging.handlers.rst
+++ b/Doc/library/logging.handlers.rst
@@ -84,6 +84,9 @@ sends logging output to a disk file. It inherits the output functionality from
with that encoding. If *delay* is true, then file opening is deferred until the
first call to :meth:`emit`. By default, the file grows indefinitely.
+ .. versionchanged:: 3.6
+ As well as string values, :class:`~pathlib.Path` objects are also accepted
+ for the *filename* argument.
.. method:: close()
@@ -160,6 +163,9 @@ for this value.
with that encoding. If *delay* is true, then file opening is deferred until the
first call to :meth:`emit`. By default, the file grows indefinitely.
+ .. versionchanged:: 3.6
+ As well as string values, :class:`~pathlib.Path` objects are also accepted
+ for the *filename* argument.
.. method:: reopenIfNeeded()
@@ -287,6 +293,9 @@ module, supports rotation of disk log files.
:file:`app.log.2`, etc. exist, then they are renamed to :file:`app.log.2`,
:file:`app.log.3` etc. respectively.
+ .. versionchanged:: 3.6
+ As well as string values, :class:`~pathlib.Path` objects are also accepted
+ for the *filename* argument.
.. method:: doRollover()
@@ -365,6 +374,10 @@ timed intervals.
.. versionchanged:: 3.4
*atTime* parameter was added.
+ .. versionchanged:: 3.6
+ As well as string values, :class:`~pathlib.Path` objects are also accepted
+ for the *filename* argument.
+
.. method:: doRollover()
Does a rollover, as described above.