Python25: wrong sys.path for pythonw2.5
Bas den Hond
lists at butdifferent.com
Sat Feb 9 00:24:27 PST 2008
Hi all,
There is a problem with python25 that may be a bug, but it's so
fundamental that maybe I'm just doing something wrong.
After installing python25 I can install a couple of modules and in a
program import them without a problem.
But if I call pythonw2.5 to execute the program, the modules are not
found. The problem is clearly the search path, which is somehow
different for pythonw2.5.
Is there a way to solve this, or should I just report a bug?
Any help appreciated.
Bas
==============
Details:
In python2.5 sys.path is:
['', '/opt/local/lib/python25.zip', '/opt/local/lib/python2.5', '/opt/
local/lib/python2.5/plat-darwin', '/opt/local/lib/python2.5/plat-mac',
'/opt/local/lib/python2.5/plat-mac/lib-scriptpackages', '/opt/local/
lib/python2.5/lib-tk', '/opt/local/lib/python2.5/lib-dynload', '/opt/
local/lib/python2.5/site-packages']
Whereas in pythonw2.5 it is:
['', '/System/Library/Frameworks/Python.framework/Versions/2.5/lib/
python25.zip', '/System/Library/Frameworks/Python.framework/Versions/
2.5/lib/python2.5', '/System/Library/Frameworks/Python.framework/
Versions/2.5/lib/python2.5/plat-darwin', '/System/Library/Frameworks/
Python.framework/Versions/2.5/lib/python2.5/plat-mac', '/System/
Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/plat-
mac/lib-scriptpackages', '/System/Library/Frameworks/Python.framework/
Versions/2.5/Extras/lib/python', '/System/Library/Frameworks/
Python.framework/Versions/2.5/lib/python2.5/lib-tk', '/System/Library/
Frameworks/Python.framework/Versions/2.5/lib/python2.5/lib-dynload', '/
Library/Python/2.5/site-packages', '/System/Library/Frameworks/
Python.framework/Versions/2.5/Extras/lib/python/PyObjC', '/Users/bas/
Library/Python/2.5/site-packages']
==============
More information about the macports-users
mailing list