[mod_python] PythonPath problem

Shuying Wang shuying at gmail.com
Wed Mar 30 22:13:43 EST 2005


On Wed, 30 Mar 2005 21:23:51 -0500, Graham Dumpleton
<grahamd at dscpl.com.au> wrote:
> Try passing the actual directory in which the modules are located
> into the import_module() function. Ie.,
> where "directory" is substituted with the actual path. By passing it
> explicitly, you avoid the whole PythonPath problem as it will look
> specifically in the specified directory.

That works but I don't understand why the PythonPath directive can't
do the same thing. Hardcoding the path into a couple of files is fine,
but doing that for several hundred files isn't really ideal.

thanks,
Shuying


More information about the Mod_python mailing list