summaryrefslogtreecommitdiffstats
path: root/Lib/platform.py
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2011-03-06 09:26:32 (GMT)
committerGeorg Brandl <georg@python.org>2011-03-06 09:26:32 (GMT)
commitfe09a54280a56a01402f4cb98c8c6cb4be89654a (patch)
tree7bea7a6d99ae4509b5f77fca934ec32f8a93c8ab /Lib/platform.py
parentf874debbf37636b0f2f46f8db06be50c20b670a8 (diff)
parent13039c87f14aeed325bcb5fadd202922a614957b (diff)
downloadcpython-fe09a54280a56a01402f4cb98c8c6cb4be89654a.zip
cpython-fe09a54280a56a01402f4cb98c8c6cb4be89654a.tar.gz
cpython-fe09a54280a56a01402f4cb98c8c6cb4be89654a.tar.bz2
Merge build identification to default branch.
Diffstat (limited to 'Lib/platform.py')
-rwxr-xr-xLib/platform.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/Lib/platform.py b/Lib/platform.py
index ab0f92f..f6394ab 100755
--- a/Lib/platform.py
+++ b/Lib/platform.py
@@ -1311,7 +1311,9 @@ def _sys_version(sys_version=None):
name = 'CPython'
builddate = builddate + ' ' + buildtime
- if hasattr(sys, 'subversion'):
+ if hasattr(sys, '_mercurial'):
+ _, branch, revision = sys._mercurial
+ elif hasattr(sys, 'subversion'):
# sys.subversion was added in Python 2.5
_, branch, revision = sys.subversion
else: