From a35ca3bb2f7e025270a7b305c133b57f917e0ef2 Mon Sep 17 00:00:00 2001 From: "Jason R. Coombs" Date: Fri, 16 May 2014 00:29:36 -0400 Subject: Use compat for Python 3 detection --- setuptools/command/egg_info.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'setuptools/command/egg_info.py') diff --git a/setuptools/command/egg_info.py b/setuptools/command/egg_info.py index 88027dd0..50c2096a 100755 --- a/setuptools/command/egg_info.py +++ b/setuptools/command/egg_info.py @@ -10,7 +10,7 @@ from setuptools import Command import distutils.errors from distutils import log from setuptools.command.sdist import sdist -from setuptools.compat import basestring +from setuptools.compat import basestring, PY3 from setuptools import svn_utils from distutils.util import convert_path from distutils.filelist import FileList as _FileList @@ -213,7 +213,7 @@ class FileList(_FileList): self.files.append(path) def _safe_path(self, path): - if sys.version_info >= (3,): + if PY3: try: if os.path.exists(path) or os.path.exists(path.encode('utf-8')): return True -- cgit v1.2.1