[Pythonmac-SIG] import question
Bob Ippolito
bob at redivi.com
Fri Nov 7 10:32:43 EST 2003
On Nov 7, 2003, at 8:38 AM, Jack Jansen wrote:
> Bobs statement about .pth files being better than mucking with
> PYTHONPATH is only partially correct. It really depends on the effect
> you want to achieve:
>
> 1. If you want to extend your Python installation system-wide with
> some additional stuff use a .pth file in a standard place.
> 2. If you want to have some modules on sys.path for your own personal
> use only use $PYTHONPATH.
>
> And, actually, for both the best solution is often to put your
> additions in $prefix/lib/python2.3/site-packages and
> ~/Library/Python/2.3/site-packages, respectively, and not add anything
> to sys.path.
Or you could put your pth file in ~/Library/Python/2.3/site-packages,
if you wanted it for your own personal use.
I still think that PYTHONPATH is still only useful for modifying
sys.path before site.py is imported, or if it doesn't get imported.
-bob
More information about the Pythonmac-SIG
mailing list