Christoph Mewes
sanji at klassenfeind.org
Thu Oct 19 02:27:59 EDT 2006
Finally, that worked for me. I created the registry keys both for 2.4, 2.4.1 and 2.5 and now everything works fine. Thanks alot. 2006/10/19, Graham Dumpleton <grahamd at dscpl.com.au>: > Since I don't use Windows, my knowledge on how to address this is limited. > There was a prior post on the mailing list: > > http://www.modpython.org/pipermail/mod_python/2006-September/021979.html > > which talks about windows registry settings indicating where Python is > installed. You might ensure that the PythonPath setting includes the > site-packages directory. > > Otherwise, will have to wait until some of the Windows people can give > you an answer. > > Graham > > Christoph Mewes wrote .. > > I have the directory > > > > E:\Software\Python-2.4.1\Lib\site-packages\mod_python. > > > > Python shows what you expected ("ImportError: No module named > > _apache"). The path list reads as follows: > > > > ['', 'E:\\Software\\Python-2.4.1\\python24.zip', 'E:\\Software\\Python-2.4.1', > > ' > > E:\\Software\\Python-2.4.1\\DLLs', 'E:\\Software\\Python-2.4.1\\lib', 'E:\\Softw > > are\\Python-2.4.1\\lib\\plat-win', 'E:\\Software\\Python-2.4.1\\lib\\lib-tk', > > 'E > > :\\Software\\Python-2.4.1\\lib\\site-packages'] > > > > Apache reported the "path used": > > > > ['E:\\\\Software\\\\Python-2.4.1\\\\python24.zip', '.\\\\DLLs', > > '.\\\\lib', '.\\\\lib\\\\plat-win', '.\\\\lib\\\\lib-tk', > > 'E:\\\\Software\\\\Apache-2.2\\\\bin'] > > > > Christoph > > > > (This time I used "Rely to all" in Google Mail) > > > > 2006/10/19, Graham Dumpleton <grahamd at dscpl.com.au>: > > > Please use REPLY-ALL and keep followups on the mailing list. > > > > > > Christoph Mewes wrote .. > > > > I have XP Home, so I cannot really change user rights. > > > > My installation works perfectly, I can run Python scrits both from > > the > > > > interactive mode and via .py-files (outputting to the cmd). > > > > > > > > 2006/10/19, Graham Dumpleton <grahamd at dscpl.com.au>: > > > > > Apache on Win32 generally runs as a special user. That user must > > have > > > > > access rights to the Python installation. Go through each of the > > directories > > > > > listed in the log output and make sure it is where the Python bits > > are > > > > > installed and then check the access rights to make sure the user > > Apache > > > > > runs on can read the files located there. If the files aren't even > > in > > > > those > > > > > locations, then your Python installation is stuffed up. Can you run > > normal > > > > > Python scripts outside of Apache? > > > > > > Do any of the directories listed in the path output in the log > > > file contain a subdirectory called 'mod_python'? > > > > > > If you run Python and do: > > > > > > from mod_python import psp > > > > > > what does it output? > > > > > > You want it to say: > > > > > > ImportError: No module named _apache > > > > > > If it complains that it can't even find 'mod_python' module, > > > then the mod_python installation is wrong. > > > > > > Also run within Python: > > > > > > import sys > > > print sys.path > > > > > > is the path the same as that in the Apache log file? > > > > > > > > > Graham > > > >
|