[issue1082] platform system may be Windows or Microsoft since Vista

Pat LaVarre report at bugs.python.org
Tue Sep 18 22:56:40 CEST 2007


Pat LaVarre added the comment:

Thanks for the cultural education of 2.5.1 isn't supposed to work, I 
didn't know that.

Also I'm glad to hear this is fixed for 2.5.2 already.

Sorry I'm too new & ignorant to understand why you believe this is 
fixed. I don't see that we already have a way to say things like:

if not platform.system('Linux'):

Do we have a way to say things like that?

My first Googles, tried here now at Mac OS X, give me useless 
suggestions like:

>>> platform.platform(aliased=True)
'Darwin-9.0.0b5-i386-32bit'
>>> platform.system_alias(platform.system(), platform.release(), 
platform.version())
('Darwin', '9.0.0b5', 'Darwin Kernel Version 9.0.0b5: Fri Aug 17 
17:24:24 PDT 2007; root:xnu-1182~1/RELEASE_I386')
>>> 

Practically speaking, I was getting by ok with:

if platform.system() != 'Windows':

Until that broke in Vista plus 2.5.1.

__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue1082>
__________________________________


More information about the Python-bugs-list mailing list