Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #50 from oscarbenjamin/fixsetup

Don't use ImportError to check python version in setup.py
  • Loading branch information...
commit 7bb9c957efaf7dcab4977f73c3ee8224c4c6c94d 2 parents f83e680 + 3fda077
@piranha authored
Showing with 3 additions and 4 deletions.
  1. +3 −4 setup.py
View
7 setup.py
@@ -1,14 +1,13 @@
#!/usr/bin/env python
-import os, re
+import sys, os, re
from distutils.core import setup
# Use 2to3 build conversion if required
-try:
+if sys.version_info >= (3, 0):
from distutils.command.build_py import build_py_2to3 as build_py
-except ImportError:
- # 2.x
+else:
from distutils.command.build_py import build_py
def read(fname):
Please sign in to comment.
Something went wrong with that request. Please try again.