platform.version() not suitable for determining if using python 3
In the file python3_compat.py this line:
_IS_PYTHON_3 = (platform.version() >= '3')
is not a sufficient method for determing if python 3 is being used. For example on my machine this returns #86-Ubuntu SMP Mon May 4 04:32:59 UTC 2015 and I'm running python 3.4.
Ideally we should use something like 2to3, but we might be able to use sys.version.
Maybe it should be using platform.python_version() ?
Actually, should be using:
import sys if sys.version_info >= (3, 0):
Six is doing this way
PY3 = sys.version_info[0] == 3
PY2 = sys.version_info[0] == 2
if PY3:
...
else:
...
https://github.com/kelp404/six/blob/master/six.py
https://github.com/dsc/bunch/pull/40 Please fix it.