fixed a problem with pypy detection

This commit is contained in:
Massimo DiPierro
2011-12-03 01:04:18 -06:00
parent ec2addf0ef
commit eaa7b651eb
2 changed files with 3 additions and 2 deletions
+1 -1
View File
@@ -1 +1 @@
Version 1.99.3 (2011-12-03 00:35:14) dev
Version 1.99.3 (2011-12-03 01:04:16) dev
+2 -1
View File
@@ -47,7 +47,8 @@ try:
except:
logger.warning('unable to import py_compile')
is_pypy = True if platform.python_implementation() == 'PyPy' else False
is_pypy = hasattr(platform,'python_implementation') and \
platform.python_implementation() == 'PyPy'
settings.global_settings.is_pypy = is_pypy
is_gae = settings.global_settings.web2py_runtime_gae
is_jython = settings.global_settings.is_jython = 'java' in sys.platform.lower() or hasattr(sys, 'JYTHON_JAR') or str(sys.copyright).find('Jython') > 0