[PEAK] dumb question about easy_install
Michael Bayer
mike_mp at zzzcomputing.com
Wed Jun 28 18:40:15 EDT 2006
OK, im just not understanding how to override a site-packages egg
install with a local (development) install, egg or otherwise.
i have the package installed as a setuptools egg in the global site-
packages. normally, this is what i want. PYTHONPATH is not set.
but then, I want to be able to cd into a directory somewhere where
theres a newer/older version of the package, and run some scripts
against that one.
I cd into my local checkout of the same application. say its in a
directory "sa020" and the python files are in "./lib/sqlalchemy/".
cd ~/sa020/
export PYTHONPATH=./lib/
python setup.py develop -d ./lib/
which completes its install fine, although ive found if you run the
exact same command a second time, you get the error "Too many open
files", until you go and delete the files setuptools created.
anyway, if I run python and look at sys.path, my local "./lib"
version is still after the site-packages "egg" version; this is
confirmed if i "import sqlalchemy" and look at its __file__; its
still on the site-packages one. so it essentially is not working
(not the way im expecting, at least).
the only way I can get it to work is like this:
sudo python setup.py develop
which overrides the site-packages version, but also requires root
access. how would I do this without requiring root access ?
More information about the PEAK
mailing list