PROBLEM with MOD_PYTHON

D

dan84

I don't understand this error , in the (Apache) errorlog I read this
message :

[Sat Oct 28 14:04:03 2006] [error] make_obcallback: could not import
mod_python.apache.\n
[Sat Oct 28 14:04:03 2006] [error] make_obcallback: Python path being
used "['C:\\\\Python24\\\\python24.zip', '.\\\\DLLs', '.\\\\lib',
'.\\\\lib\\\\plat-win', '.\\\\lib\\\\lib-tk',
'C:\\\\Programmi\\\\Apache Group\\\\Apache2\\\\bin']".
[Sat Oct 28 14:04:03 2006] [error] python_handler: no interpreter
callback found.
[Sat Oct 28 14:04:03 2006] [error] [client 127.0.0.1] python_handler:
Can't get/create interpreter.

I have Apache/2.0.59 (Win32) mod_python/3.2.10 Python/2.4.3
I have read all the manuals, but I don't understand where I am wrong.

thanks so much
Marco.
 
C

Chetan

dan84 said:
I don't understand this error , in the (Apache) errorlog I read this
message :

[Sat Oct 28 14:04:03 2006] [error] make_obcallback: could not import
mod_python.apache.\n
[Sat Oct 28 14:04:03 2006] [error] make_obcallback: Python path being
used "['C:\\\\Python24\\\\python24.zip', '.\\\\DLLs', '.\\\\lib',
'.\\\\lib\\\\plat-win', '.\\\\lib\\\\lib-tk',
'C:\\\\Programmi\\\\Apache Group\\\\Apache2\\\\bin']".
[Sat Oct 28 14:04:03 2006] [error] python_handler: no interpreter
callback found.
[Sat Oct 28 14:04:03 2006] [error] [client 127.0.0.1] python_handler:
Can't get/create interpreter.

I have Apache/2.0.59 (Win32) mod_python/3.2.10 Python/2.4.3
I have read all the manuals, but I don't understand where I am wrong.

thanks so much
Marco.
Even if there is nothing Apache specific, doesn't it look odd that the
path has 4 backslashes? Even accounting for half of those being added at the
time of printing, it would appear that Apache is trying to use the path that
contains two backslashes as path separator but there needs to be only one.

Chetan
 
J

J. Clifford Dyer

dan84 said:
I don't understand this error , in the (Apache) errorlog I read this
message :

[Sat Oct 28 14:04:03 2006] [error] make_obcallback: could not import
mod_python.apache.\n
[Sat Oct 28 14:04:03 2006] [error] make_obcallback: Python path being
used "['C:\\\\Python24\\\\python24.zip', '.\\\\DLLs', '.\\\\lib',
'.\\\\lib\\\\plat-win', '.\\\\lib\\\\lib-tk',
'C:\\\\Programmi\\\\Apache Group\\\\Apache2\\\\bin']".

The four backslashes look okay to me, since there are "s outside the
list, viz:
>>> mylist = [ r'C:\Python24' ]
>>> mylist ['C:\\Python24']
>>> repr(mylist)
"['C:\\\\Python24']"


Back to your question: Where is mod_python located? Is it anywhere in
this path? Go to each directory/zip file, and see if you find
mod_python. If so, is your base directory where you think it is? (use
os.getcwd() to find out). If mod_python is still not in there, where is
it? Now add THAT directory to your Python path.

Cheers,
Cliff
 
S

skip

dan> I don't understand this error , in the (Apache) errorlog I read
dan> this message :

dan> [Sat Oct 28 14:04:03 2006] [error] make_obcallback: could not import
dan> mod_python.apache.\n
dan> [Sat Oct 28 14:04:03 2006] [error] make_obcallback: Python path being
dan> used "['C:\\\\Python24\\\\python24.zip', '.\\\\DLLs', '.\\\\lib',
dan> '.\\\\lib\\\\plat-win', '.\\\\lib\\\\lib-tk',
dan> 'C:\\\\Programmi\\\\Apache Group\\\\Apache2\\\\bin']".
dan> [Sat Oct 28 14:04:03 2006] [error] python_handler: no interpreter
dan> callback found.
dan> [Sat Oct 28 14:04:03 2006] [error] [client 127.0.0.1] python_handler:
dan> Can't get/create interpreter.

Just a wild ass guess, but maybe Apache can't find the necessary python dll
to load?

Skip
 
G

grahamd

dan84 said:
I don't understand this error , in the (Apache) errorlog I read this
message :

[Sat Oct 28 14:04:03 2006] [error] make_obcallback: could not import
mod_python.apache.\n
[Sat Oct 28 14:04:03 2006] [error] make_obcallback: Python path being
used "['C:\\\\Python24\\\\python24.zip', '.\\\\DLLs', '.\\\\lib',
'.\\\\lib\\\\plat-win', '.\\\\lib\\\\lib-tk',
'C:\\\\Programmi\\\\Apache Group\\\\Apache2\\\\bin']".
[Sat Oct 28 14:04:03 2006] [error] python_handler: no interpreter
callback found.
[Sat Oct 28 14:04:03 2006] [error] [client 127.0.0.1] python_handler:
Can't get/create interpreter.

I have Apache/2.0.59 (Win32) mod_python/3.2.10 Python/2.4.3
I have read all the manuals, but I don't understand where I am wrong.

thanks so much
Marco.

Read:


http://www.modpython.org/pipermail/mod_python/2006-October/022362.html

You may have to fiddle your Windows registry to add site-packages
directory.

BTW, there is a mailing list specifically for mod_python. You might be
better off asking questions directly there, as we have seen most
problems. You can also search the mailing list archives from the
mod_python site.

BTW, the quadruple backslashes is indeed because of the use of repr()
when doing the error dump.

Graham
 
S

Steve Holden

BTW, there is a mailing list specifically for mod_python. You might be
better off asking questions directly there, as we have seen most
problems. You can also search the mailing list archives from the
mod_python site.

BTW, the quadruple backslashes is indeed because of the use of repr()
when doing the error dump.

For gmane users the list is also available as newsgroup

gmane.comp.python.mod_python

regards
Steve
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,763
Messages
2,569,563
Members
45,039
Latest member
CasimiraVa

Latest Threads

Top