On 10/30/06, Michael Bayer <[EMAIL PROTECTED]> wrote: > > On Oct 30, 2006, at 3:00 PM, Bob Ippolito wrote: > > Feature. It can do multi-version installs, but only if explicitly > > specified. > > > > The problem is that 1.2.1 is already on sys.path, so setuptools gives > > up because it doesn't know if something is using Gnosis-Utils or not. > > If the directory *containing* the egg was on sys.path, then it would > > pick the exact version... but then you must *always* require it before > > it is imported. > > Ah, terrific. -m allows this feature, although i wonder why -m then > makes regular "import", for those scripts that just want the default > version, not useable (but i have not yet searched for this answer, so > feel free to ignore).
You're thinking about this backwards. Multi-version installs don't "make import unusable", they simply skip the step that adds the contents of the egg to sys.path. That is the only thing that differentiates a normal install and a multi-version install. The reason multi-version works at all is because it's sure that nothing in the egg is already in use by Python because it doesn't live on sys.path so none of its contents can possibly be loaded into the interpreter. Require looks for eggs and adds the best match to sys.path. -bob _______________________________________________ Distutils-SIG maillist - [email protected] http://mail.python.org/mailman/listinfo/distutils-sig
