[New-bugs-announce] [issue16176] platform.platform() identifies Windows 8 as post2008Server

Brian Curtin report at bugs.python.org
Tue Oct 9 18:12:22 CEST 2012


New submission from Brian Curtin:

>>> platform.platform()
'Windows-post2008Server-6.2.9200'

The change is trivial, just accounting for a point release of 2 (from the major release 6).

--- a/Lib/platform.py
+++ b/Lib/platform.py
@@ -595,8 +595,13 @@
                     release = '7'
                 else:
                     release = '2008ServerR2'
+            elif min == 2:
+                if product_type == VER_NT_WORKSTATION:
+                    release = '8'
+                else:
+                    release = '2012Server'
             else:
-                release = 'post2008Server'
+                release = 'post2012Server'

----------
assignee: brian.curtin
components: Library (Lib), Windows
messages: 172490
nosy: brian.curtin
priority: normal
severity: normal
status: open
title: platform.platform() identifies Windows 8 as post2008Server
type: behavior
versions: Python 2.7, Python 3.2, Python 3.3, Python 3.4

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue16176>
_______________________________________


More information about the New-bugs-announce mailing list