Clark
foo.Clark at gmail.com
Sun Jun 12 02:38:23 EDT 2005
I think it's a bug of mod_python 3.1.3 You can try the python script as follows: import mod_python for i in mod_python: req.write(i) req.write(<br>) The output is __all__ __builtins__ __doc__ __file__ __name__ __path__ apache util Three modules including psp, cgihandler and publisher miss. I haven't tested mod_python 3.1.4. Maybe you can try this one. On Sat, Jun 11, 2005 at 03:07:36PM -0300, Adriano Monteiro wrote: > Sure!! > > My apache configuration: > > <Directory /var/www/quiron> > AddHandler mod_python .psp .py > DirectoryIndex Index.psp > PythonHandler mod_python.psp | .psp > PythonHandler mod_python.publisher | .py > PythonDebug On > </Directory> > > Apache 2.0.53 and mod_python 3.1.3 > > I've created a python script to handle control flow and psp file to > handle the vision. > Within the pytho script I create a psp.PSP instance and call the run > method of the object. > > >From time to time, I got error on psp import. > > I just can't understand why... > > My import line: > from mod_python import psp > > How I call it: > > obj = psp.PSP (req, 'file.psp') > obj.run ({'var':1}) > > Something that I'm doing wrong? > > Regards, > > > On 6/11/05, Clark <foo.Clark at gmail.com> wrote: > > Maybe you'd better show your python script and mod_python configuration > > (or give a simple example) to help us understand your problem. > > > > On Sat, Jun 11, 2005 at 02:08:37PM -0300, Adriano Monteiro wrote: > > > Hi folks! > > > > > > I'm getting this error from time to time: > > > > > > Mod_python error: "PythonHandler mod_python.publisher" > > > > > > Traceback (most recent call last): > > > > > > File "/usr/lib/python2.4/site-packages/mod_python/apache.py", line > > > 299, in HandlerDispatch > > > result = object(req) > > > > > > File "/usr/lib/python2.4/site-packages/mod_python/publisher.py", > > > line 98, in handler > > > path=[path]) > > > > > > File "/usr/lib/python2.4/site-packages/mod_python/apache.py", line > > > 457, in import_module > > > module = imp.load_module(mname, f, p, d) > > > > > > File "/var/www/quiron/core/CadastrarUsuario.py", line 17, in ? > > > from mod_python import apache, psp > > > > > > ImportError: cannot import name psp > > > > > > I don't undesrtand why is this happening. I saw some threads that have > > > already talked about this problem, but I didn't find any solution! > > > I'm almost quiting. I'll have to change the language of my project > > > because of this problem if it persist.. > > > > > > []'s! > > > > > > -- > > > > > > Adriano Monteiro Marques > > > www.gopython.com.br > > > py.adriano at gmail.com > > > > > > I'm FREE... Are you? > > > (PYTHON powered) > > > > > > _______________________________________________ > > > Mod_python mailing list > > > Mod_python at modpython.org > > > http://mailman.modpython.org/mailman/listinfo/mod_python > > _______________________________________________ > > Mod_python mailing list > > Mod_python at modpython.org > > http://mailman.modpython.org/mailman/listinfo/mod_python > > > > > -- > > Adriano Monteiro Marques > www.gopython.com.br > py.adriano at gmail.com > > I'm FREE... Are you? > (PYTHON powered) > > _______________________________________________ > Mod_python mailing list > Mod_python at modpython.org > http://mailman.modpython.org/mailman/listinfo/mod_python
|