[mod_python] Current working directory

Ragnar Kjørstad mod_python at ragnark.vestdata.no
Fri Nov 2 17:36:47 EST 2001


Hi

How does the current working directory get set when working with
mod_python?

The problem is that my handler (and modules imported by the handler) is
trying to access local files, but it can't find them because the current
directory is not set "properly". 

I tried adding os.chdir() in my handler, but it seems the cwd is still
random for modules imported from my handler.

Maybe someone could shed some light on this?

I think the best thing would be that the directory of the handler would
be the cwd both when importing the handler and other modules, but if I
could only set it manually that would also be ok.

Thanks.



-- 
Ragnar Kjørstad
Zet.no



More information about the Mod_python mailing list