[Python-checkins] r57943 - sandbox/trunk/setuptools/pkg_resources.py

phillip.eby python-checkins at python.org
Tue Sep 4 05:51:26 CEST 2007


Author: phillip.eby
Date: Tue Sep 4 05:51:25 2007
New Revision: 57943
Modified:
 sandbox/trunk/setuptools/pkg_resources.py
Log:
Fix precedence issue between .egg and .egg-info packages
when both are installed in site-packages.
Modified: sandbox/trunk/setuptools/pkg_resources.py
==============================================================================
--- sandbox/trunk/setuptools/pkg_resources.py	(original)
+++ sandbox/trunk/setuptools/pkg_resources.py	Tue Sep 4 05:51:25 2007
@@ -2148,7 +2148,8 @@
 for p, item in enumerate(npath):
 if item==nloc:
 break
- elif item==bdir:
+ elif item==bdir and self.precedence==EGG_DIST:
+ # if it's an .egg, give it precedence over its directory
 path.insert(p, loc)
 npath.insert(p, nloc)
 break
@@ -2170,7 +2171,6 @@
 
 
 
-
 def check_version_conflict(self):
 if self.key=='setuptools':
 return # ignore the inevitable setuptools self-conflicts :(


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /