[Mailman-Users] module problem

Richard M. Pavonarius rpavonar at cisco.com
Sat Mar 24 08:42:27 CET 2001

I'm having a problem getting the Japanese version of Mailman 2.0.3 to run, 
but it's not a Japanese language problem. Basically, there's a module that 
works right when I run Python via the CLI but not when it's run as a CGI. I 
read the FAQ. Didn't help.

The Japanese version uses the module kconv to convert between the encoding 
schemes used internally by Linux (euc) and e-mail (jis). I assume I 
installed the module properly because it's required to create a list 
through bin/newlist, and I can do it either as root or mailman.

After creating the list, I can access the list's page via a Web browser. 
The problem is when I try to subscribe I get the "We're sorry, we hit a 
bug!"error message. The error log file is below.

Why can Python find the module via the command line but not when it's run 
as a CGI? I assume the answer has something to do with file permissions or 
search paths, but I need some pretty specific directions on how to fix it. 
I've check the FAQ and the text in cgi.py and didn't find anything useful.

Yes, this is my first time using Python. Yes, I already asked on the 
Japanese Mailman list. The advice I got was to try using mod_snake. I got 
it to work, but not with Mailman.

Any help would be greatly appreciated. I've been trying to fix this for a 
week now.

Mar 23 16:48:10 2001 admin(22780): @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
admin(22780): [----- Mailman Version: 2.0.3+J1 -----]
admin(22780): [----- Traceback ------]
admin(22780): Traceback (innermost last):
admin(22780):   File "/home/mailman/scripts/driver", line 96, in run_main
admin(22780):     main()
admin(22780):   File "../Mailman/Cgi/subscribe.py", line 53, in main
admin(22780):     process_form(mlist, doc)
admin(22780):   File "../Mailman/Cgi/subscribe.py", line 164, in process_form
admin(22780):     mlist.AddMember(email, pw, digest, remote)
admin(22780):   File "../Mailman/MailList.py", line 1017, in AddMember
admin(22780):     HandlerAPI.DeliverToUser(self, msg)
admin(22780):   File "../Mailman/Handlers/HandlerAPI.py", line 186, in DeliverTo
admin(22780):     return DeliverToList(mlist, msg, msgdata)
admin(22780):   File "../Mailman/Handlers/HandlerAPI.py", line 152, in DeliverTo
admin(22780):     pipeline = do_pipeline(mlist, msg, msgdata, pipeline)
admin(22780):   File "../Mailman/Handlers/HandlerAPI.py", line 81, in do_pipelin
admin(22780):     mod = __import__('Mailman.Handlers.' + modname)
admin(22780):   File "../Mailman/Handlers/to_jis.py", line 3, in ?
admin(22780):     import kconv,sys,re,base64,string
admin(22780): ImportError: No module named kconv
admin(22780): [----- Python Information -----]
admin(22780): sys.version    = 1.5.2 (#1, Nov 28 2000, 14:34:21)  [GCC 2.95.2 19
991024 (release)]
admin(22780): sys.executable = /usr/bin/python
admin(22780): sys.prefix     = /usr
admin(22780): sys.exec_prefix= /usr
admin(22780): sys.path       = /usr
admin(22780): sys.platform   = linux-i586
admin(22780): [----- Environment Variables -----]
admin(22780):   DOCUMENT_ROOT: /home/httpd/html
admin(22780):   SERVER_ADDR:
admin(22780):   HTTP_ACCEPT_ENCODING: gzip
admin(22780):   CONTENT_LENGTH: 112
admin(22780):   CONTENT_TYPE: application/x-www-form-urlencoded
admin(22780):   PATH_TRANSLATED: /home/httpd/html/test
admin(22780):   REMOTE_ADDR:
admin(22780):   HTTP_COOKIE: test:admin=
admin(22780):   SERVER_PROTOCOL: HTTP/1.0
admin(22780):   HTTP_ACCEPT_LANGUAGE: ja,en
admin(22780):   GATEWAY_INTERFACE: CGI/1.1
admin(22780):   SERVER_PORT: 80
admin(22780):   HTTP_USER_AGENT: Mozilla/4.75 [ja] (Win98; U)
admin(22780):   HTTP_ACCEPT_CHARSET: Shift_JIS,*,utf-8
admin(22780):   HTTP_ACCEPT: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg
, image/png, */*
admin(22780):   REQUEST_URI: /mailman/subscribe/test
admin(22780):   QUERY_STRING:
admin(22780):   SCRIPT_FILENAME: /home/mailman/cgi-bin/subscribe
admin(22780):   PATH_INFO: /test
admin(22780):   HTTP_HOST: academy-if.cisco.com
admin(22780):   REQUEST_METHOD: POST
admin(22780):   SERVER_SIGNATURE: <ADDRESS>Apache/1.3.14 Server at academy-if.ci
sco.com Port 80</ADDRESS>

admin(22780):   SCRIPT_NAME: /mailman/subscribe
admin(22780):   SERVER_ADMIN: rpavonar at cisco.com
admin(22780):   SERVER_SOFTWARE: Apache/1.3.14 (Unix)  (Trustix Secure Linux/Lin
admin(22780):   PYTHONPATH: /home/mailman
admin(22780):   HTTP_REFERER: http://academy-if.cisco.com/mailman/listinfo/test
admin(22780):   SERVER_NAME: academy-if.cisco.com
admin(22780):   REMOTE_PORT: 41018

More information about the Mailman-Users mailing list