Skip to content

Commit 2fc1c6a

Browse files
committed
pythongh-120713: revised detection logics in Python
1 parent a9623c4 commit 2fc1c6a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Lib/_pydatetime.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -210,9 +210,9 @@ def _need_normalize_century():
210210
if _normalize_century is None:
211211
try:
212212
_normalize_century = (
213-
_time.strftime("%Y", (99, 1, 1, 0, 0, 0, 0, 1, 0)) == "99")
213+
_time.strftime("%Y", (99, 1, 1, 0, 0, 0, 0, 1, 0)) != "0099")
214214
except ValueError:
215-
_normalize_century = False
215+
_normalize_century = True
216216
return _normalize_century
217217

218218
# Correctly substitute for %z and %Z escapes in strftime formats.

0 commit comments

Comments
 (0)