[Python-checkins] gh-101041: Fix a misspelled name of `utctimetuple` in a doc warning (GH-101042)
miss-islington
webhook-mailer at python.org
Fri Jan 20 00:06:54 EST 2023
https://github.com/python/cpython/commit/1998ea69c7739bc833baca47849f33e84fa337df
commit: 1998ea69c7739bc833baca47849f33e84fa337df
branch: 3.11
author: Miss Islington (bot) <31488909+miss-islington at users.noreply.github.com>
committer: miss-islington <31488909+miss-islington at users.noreply.github.com>
date: 2023-01-19T21:06:47-08:00
summary:
gh-101041: Fix a misspelled name of `utctimetuple` in a doc warning (GH-101042)
(cherry picked from commit 8e9d08b062bbabfe439bc73f82e3d7bb3800189e)
Co-authored-by: Oleg Iarygin <oleg at arhadthedev.net>
files:
M Doc/library/datetime.rst
diff --git a/Doc/library/datetime.rst b/Doc/library/datetime.rst
index e700b0a1347a..c7b96671eff7 100644
--- a/Doc/library/datetime.rst
+++ b/Doc/library/datetime.rst
@@ -1350,7 +1350,7 @@ Instance methods:
Because naive ``datetime`` objects are treated by many ``datetime`` methods
as local times, it is preferred to use aware datetimes to represent times
- in UTC; as a result, using ``utcfromtimetuple`` may give misleading
+ in UTC; as a result, using :meth:`datetime.utctimetuple` may give misleading
results. If you have a naive ``datetime`` representing UTC, use
``datetime.replace(tzinfo=timezone.utc)`` to make it aware, at which point
you can use :meth:`.datetime.timetuple`.
More information about the Python-checkins
mailing list