From: Lysandros Nikolaou Date: Wed, 11 Sep 2019 15:08:10 +0000 (+0300) Subject: bpo-36182: Update pathlib.Path.write_text() docs (GH-12161) X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=af636f4f91b8289b6dad95cb84123f6e22fd7f4f;p=python bpo-36182: Update pathlib.Path.write_text() docs (GH-12161) with the case of an existing file --- diff --git a/Doc/library/pathlib.rst b/Doc/library/pathlib.rst index d33e2d0c89..acbd0e48af 100644 --- a/Doc/library/pathlib.rst +++ b/Doc/library/pathlib.rst @@ -1119,6 +1119,9 @@ call fails (for example because the path doesn't exist). >>> p.read_text() 'Text file contents' + An existing file of the same name is overwritten. The optional parameters + have the same meaning as in :func:`open`. + .. versionadded:: 3.5 Correspondence to tools in the :mod:`os` module