diff options
author | spacemanspiff2007 <10754716+spacemanspiff2007@users.noreply.github.com> | 2024-10-08 18:17:53 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-10-08 18:17:53 (GMT) |
commit | 760b1e103a0aa696cdf448e0d500cd1bac2213fa (patch) | |
tree | 0076fcc3e411fd52586d3e53dc300478d64a21e9 /Doc/library | |
parent | c6127af8685c2a9b416207e46089cee79d028b85 (diff) | |
download | cpython-760b1e103a0aa696cdf448e0d500cd1bac2213fa.zip cpython-760b1e103a0aa696cdf448e0d500cd1bac2213fa.tar.gz cpython-760b1e103a0aa696cdf448e0d500cd1bac2213fa.tar.bz2 |
gh-124832: Add a note to indicate that `datetime.now` may return the same instant (#124834)
* Update datetime.rst
* Update datetime.rst
replace warning with note
* Update Doc/library/datetime.rst
Co-authored-by: Victor Stinner <vstinner@python.org>
* Update Doc/library/datetime.rst
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
---------
Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Diffstat (limited to 'Doc/library')
-rw-r--r-- | Doc/library/datetime.rst | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Doc/library/datetime.rst b/Doc/library/datetime.rst index 64510a7..f0b465b 100644 --- a/Doc/library/datetime.rst +++ b/Doc/library/datetime.rst @@ -948,6 +948,10 @@ Other constructors, all class methods: This function is preferred over :meth:`today` and :meth:`utcnow`. + .. note:: + + Subsequent calls to :meth:`!datetime.now` may return the same + instant depending on the precision of the underlying clock. .. classmethod:: datetime.utcnow() |