[mod_python] PythonImport

Gregory Trubetskoy grisha at modpython.org
Fri Aug 11 17:25:14 EST 2000


Is your PythonImport within an appropriate <Directory> tag or just by
itself?

--
  Gregory (Grisha) Trubetskoy
       grisha at modpython.org

On Fri, 11 Aug 2000, Daniel Mikkelsen wrote:

> Hi.
> 
> I'm having problems with loading modules not located in the global
> site-packages directory. 
> 
> I want to load a module that opens a connection to a database, and
> I want this module to be located in the same directory as the .py
> files that will make use of it. 
> 
> However, I always get:
> 
>   Fri Aug 11 21:16:46 2000] [error] directive_PythonImport: error
>   importing open_db_con ImportError: No module named open_db_con
> 
> If I copy the module into site-packages, this works. But I don't want
> do this, as I expect to have lots of different programs that will 
> want to access lots of different databases. 
> 
> I've tried using the PythonPath directive, to no avail. I'm using 
> mod_python 2.4.1 loaded dynamically with Apache 1.3.9 on OpenBSD 2.6. 
> 
> Anything obvious I'm doing wrong?
> 
> -- Daniel Mikkelsen, Copyleft Software
> 
> 
> _______________________________________________
> Mod_python mailing list
> Mod_python at modpython.org
> http://www.modpython.org/mailman/listinfo/mod_python
> 




More information about the Mod_python mailing list