[Subversion] / ez_setup / __init__.py  

Diff of /ez_setup/__init__.py

Parent Directory | Revision Log

version 2758, Sat Apr 4 23:11:06 2015 UTC version 2759, Sat Apr 4 23:56:09 2015 UTC
Line 70 
Line 70 
     if egg_name in md5_data:      if egg_name in md5_data:
         digest = md5(data).hexdigest()          digest = md5(data).hexdigest()
         if digest != md5_data[egg_name]:          if digest != md5_data[egg_name]:
             print >>sys.stderr, (              sys.stderr.write(
                 "md5 validation of %s failed!  (Possible download problem?)"                  "md5 validation of %s failed!  (Possible download problem?)\n"
                 % egg_name                  % egg_name
             )              )
             sys.exit(2)              sys.exit(2)
Line 103 
Line 103 
         return do_download()          return do_download()
     try:      try:
         pkg_resources.require("setuptools>="+version); return          pkg_resources.require("setuptools>="+version); return
     except pkg_resources.VersionConflict, e:      except pkg_resources.VersionConflict:
           e = sys.exc_info()[1]
         if was_imported:          if was_imported:
             print >>sys.stderr, (              sys.stderr.write(
             "The required version of setuptools (>=%s) is not available, and\n"              "The required version of setuptools (>=%s) is not available, and\n"
             "can't be installed while this script is running. Please install\n"              "can't be installed while this script is running. Please install\n"
             " a more recent version first, using 'easy_install -U setuptools'."              " a more recent version first, using 'easy_install -U setuptools'."
             "\n\n(Currently using %r)"              "\n\n(Currently using %r)\n"
             ) % (version, e.args[0])              % (version, e.args[0]))
             sys.exit(2)              sys.exit(2)
     except pkg_resources.DistributionNotFound:      except pkg_resources.DistributionNotFound:
         pass          pass
Line 216 
Line 217 
                 os.unlink(egg)                  os.unlink(egg)
     else:      else:
         if setuptools.__version__ == '0.0.1':          if setuptools.__version__ == '0.0.1':
             print >>sys.stderr, (              sys.stderr.write(
             "You have an obsolete version of setuptools installed.  Please\n"              "You have an obsolete version of setuptools installed.  Please\n"
             "remove it from your system entirely before rerunning this script."              "remove it from your system entirely before rerunning this script.\n"
             )              )
             sys.exit(2)              sys.exit(2)
   
Line 238 
Line 239 
             from setuptools.command.easy_install import main              from setuptools.command.easy_install import main
             main(argv)              main(argv)
         else:          else:
             print "Setuptools version",version,"or greater has been installed."              print("Setuptools version",version,"or greater has been installed.")
             print '(Run "ez_setup.py -U setuptools" to reinstall or upgrade.)'              print('(Run "ez_setup.py -U setuptools" to reinstall or upgrade.)')
   
 def update_md5(filenames):  def update_md5(filenames):
     """Update our built-in md5 registry"""      """Update our built-in md5 registry"""
Line 262 
Line 263 
   
     match = re.search("\nmd5_data = {\n([^}]+)}", src)      match = re.search("\nmd5_data = {\n([^}]+)}", src)
     if not match:      if not match:
         print >>sys.stderr, "Internal error!"          sys.stderr.write("Internal error!\n")
         sys.exit(2)          sys.exit(2)
   
     src = src[:match.start(1)] + repl + src[match.end(1):]      src = src[:match.start(1)] + repl + src[match.end(1):]


Generate output suitable for use with a patch program
Legend:
Removed from v.2758  
changed lines
  Added in v.2759

cvs-admin@eby-sarna.com

Powered by ViewCVS 1.0-dev

ViewCVS and CVS Help