sys.path - stuff from nowhere?

Richard Kessler richard.kessler at matteicos.com
Fri Jul 22 15:14:50 EDT 2005


Just build python 2.3.4 (needed for Zope and Plone). Trying to learn more
about use the data in sys.path from importing. When I run Python at the
command prompt, import sys and print sys.path I get stuff that makes no
sense. For example, /usr/local/lib/python23.zip.

Such a file does not even live on my debian machine, I would like to remove
it from the sys.path string but I do not understand how it is getting there
in the first place. Can anyone tell me how sys.path is initialized other
than PYTHONPATH (which I have as /usr/local)?  I have no .pth files and
site-packages is empty at this point.

Thanks much in advance.

Richard






More information about the Python-list mailing list