From 210b649d96b3ba82098e0fe7e569fd3ebc04641e Mon Sep 17 00:00:00 2001 From: Anton Ryzhov Date: Tue, 10 Feb 2026 23:55:20 +0100 Subject: [PATCH 1/2] Update comments in `_strptime` module --- Lib/_strptime.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Lib/_strptime.py b/Lib/_strptime.py index fe34808d88769a..66869380dba931 100644 --- a/Lib/_strptime.py +++ b/Lib/_strptime.py @@ -7,7 +7,7 @@ FUNCTIONS: _getlang -- Figure out what language is being used for the locale - strptime -- Calculates the time struct represented by the passed-in string + _strptime -- Calculates the time struct represented by the passed-in string """ import os @@ -518,9 +518,10 @@ def _calc_julian_from_U_or_W(year, week_of_year, day_of_week, week_starts_Mon): def _strptime(data_string, format="%a %b %d %H:%M:%S %Y"): - """Return a 2-tuple consisting of a time struct and an int containing - the number of microseconds based on the input string and the - format string.""" + """Return a 3-tuple consisting of a time struct, an int containing + the number of microseconds and an int containing + a mictoseconds part of the GMT offset based on the input string + and the format string.""" for index, arg in enumerate([data_string, format]): if not isinstance(arg, str): From de6f859819e4b81fd364b3404bfda28a1d20052c Mon Sep 17 00:00:00 2001 From: Anton Ryzhov Date: Thu, 19 Feb 2026 21:59:28 +0100 Subject: [PATCH 2/2] Fix docsting comment Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com> --- Lib/_strptime.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Lib/_strptime.py b/Lib/_strptime.py index 66869380dba931..0d81ff6765e1ed 100644 --- a/Lib/_strptime.py +++ b/Lib/_strptime.py @@ -518,10 +518,10 @@ def _calc_julian_from_U_or_W(year, week_of_year, day_of_week, week_starts_Mon): def _strptime(data_string, format="%a %b %d %H:%M:%S %Y"): - """Return a 3-tuple consisting of a time struct, an int containing - the number of microseconds and an int containing - a mictoseconds part of the GMT offset based on the input string - and the format string.""" + """Return a 3-tuple consisting of a tuple with time components, + an int containing the number of microseconds, and an int + containing the microseconds part of the GMT offset, based on the + input string and the format string.""" for index, arg in enumerate([data_string, format]): if not isinstance(arg, str):