problem with PYTHONPATH on WinXP

Peter Hansen peter at engcorp.com
Mon May 10 06:28:54 EDT 2004


D Denholm wrote:

> I recently installed Python 2.2 on my WinXP box.
> 
> I am having problems figuring out how to create the PYTHONPATH
> correctly.

I would suggest not using PYTHONPATH, but instead use the .pth
file capability defined in and used by site.py.  Check the
comments at the top of that file in your python/lib folder,
and make a .pth file with the appropriate contents instead
of mucking with environment variables.  One thing to note:
the file extension must be lower case or site.py won't
find the file.

-Peter



More information about the Python-list mailing list