Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e42a59d

Browse files
committed
#9442: do not document a specific format for sys.version; rather refer to version_info and the platform module.
1 parent 721507b commit e42a59d

1 file changed

Lines changed: 4 additions & 9 deletions

File tree

Doc/library/sys.rst

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -935,15 +935,10 @@ always available.
935935
.. data:: version
936936

937937
A string containing the version number of the Python interpreter plus additional
938-
information on the build number and compiler used. It has a value of the form
939-
``'version (#build_number, build_date, build_time) [compiler]'``. There may be
940-
a newline character preceding the opening bracket with of the compiler info.
941-
The first three characters are used to identify the version in the installation
942-
directories (where appropriate on each platform). An example::
943-
944-
>>> import sys
945-
>>> sys.version
946-
'1.5.2 (#0 Apr 13 1999, 10:51:12) [MSC 32 bit (Intel)]'
938+
information on the build number and compiler used. This string is displayed
939+
when the interactive interpreter is started. Do not extract version information
940+
out of it, rather, use :data:`version_info` and the functions provided by the
941+
:mod:`platform` module.
947942

948943

949944
.. data:: api_version

0 commit comments

Comments
 (0)