https://github.com/python/cpython/commit/2e873f7bb1f2b52c97ff225194cb71cde93ab498
commit: 2e873f7bb1f2b52c97ff225194cb71cde93ab498
branch: 3.14
author: Serhiy Storchaka <[email protected]>
committer: serhiy-storchaka <[email protected]>
date: 2026-06-18T14:45:00Z
summary:

[3.14] gh-86726: Fix the documented return type of tkinter info_patchlevel() 
(GH-151655) (GH-151659)

It returns a sys.version_info-like named tuple, not a string.
(cherry picked from commit 3cd02a1c2da023974464fd1155982a16474f331b)

Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>

files:
M Doc/library/tkinter.rst

diff --git a/Doc/library/tkinter.rst b/Doc/library/tkinter.rst
index 4b7aae3cc559ec..e95d838506bc7d 100644
--- a/Doc/library/tkinter.rst
+++ b/Doc/library/tkinter.rst
@@ -2307,7 +2307,13 @@ Base and mixin classes
 
    .. method:: info_patchlevel()
 
-      Return the Tcl/Tk patch level as a string, for example ``'8.6.15'``.
+      Return the Tcl/Tk patch level as a named tuple with the same five fields
+      as :data:`sys.version_info`: *major*, *minor*, *micro*, *releaselevel*
+      and *serial*.
+      *releaselevel* is ``'alpha'``, ``'beta'`` or ``'final'``.
+      Converting it to a string gives the version in the usual Tcl/Tk notation,
+      for example ``'9.0.3'`` for a final release or ``'9.1b2'`` for a
+      pre-release.
 
       .. versionadded:: 3.11
 

_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]

Reply via email to