I receive the following error when the below cron job is ran, or just running it from the command line. Any suggestion on what would fix this issue? Do I have a bad digest.mbox somewhere?
/usr/local/bin/python -S /home/mailman/cron/senddigests
Traceback (most recent call last): File "/home/mailman/cron/senddigests", line 94, in ? main() File "/home/mailman/cron/senddigests", line 86, in main mlist.send_digest_now() File "/home/mailman/Mailman/Digester.py", line 60, in send_digest_now ToDigest.send_digests(self, mboxfp) File "/home/mailman/Mailman/Handlers/ToDigest.py", line 133, in send_digests send_i18n_digests(mlist, mboxfp) File "/home/mailman/Mailman/Handlers/ToDigest.py", line 315, in send_i18n_digests msg = scrubber(mlist, msg) File "/home/mailman/Mailman/Handlers/Scrubber.py", line 299, in process url = save_attachment(mlist, part, dir) File "/home/mailman/Mailman/Handlers/Scrubber.py", line 411, in save_attachment filename = Utils.oneline(msg.get_filename(''), lcset) File "/home/mailman/pythonlib/email/Message.py", line 724, in get_filename filename = self.get_param('filename', missing, 'content-disposition') File "/home/mailman/pythonlib/email/Message.py", line 607, in get_param for k, v in self._get_params_preserve(failobj, header): File "/home/mailman/pythonlib/email/Message.py", line 554, in _get_params_preserve params = Utils.decode_params(params) File "/home/mailman/pythonlib/email/Utils.py", line 337, in decode_params charset, language, value = decode_rfc2231(EMPTYSTRING.join(value)) File "/home/mailman/pythonlib/email/Utils.py", line 284, in decode_rfc2231 charset, language, s = parts ValueError: unpack list of wrong size
Kory Wheatley wrote:
I receive the following error when the below cron job is ran, or just running it from the command line. Any suggestion on what would fix this issue? Do I have a bad digest.mbox somewhere?
Probably not. You have a digest.mbox that has a message with an unusual rfc2231 encoded header (a long filename= parameter in the Content-Disposition: header of an attachment with an apostrophe in the name), but the header is probably correct. It is the Python email.Utils.decode_params() function that has the problem. This has been fixed in Python email 2.5.8 which ships with Mailman 2.1.9
/usr/local/bin/python -S /home/mailman/cron/senddigests
Traceback (most recent call last): File "/home/mailman/cron/senddigests", line 94, in ? main() File "/home/mailman/cron/senddigests", line 86, in main mlist.send_digest_now() File "/home/mailman/Mailman/Digester.py", line 60, in send_digest_now ToDigest.send_digests(self, mboxfp) File "/home/mailman/Mailman/Handlers/ToDigest.py", line 133, in send_digests send_i18n_digests(mlist, mboxfp) File "/home/mailman/Mailman/Handlers/ToDigest.py", line 315, in send_i18n_digests msg = scrubber(mlist, msg) File "/home/mailman/Mailman/Handlers/Scrubber.py", line 299, in process url = save_attachment(mlist, part, dir) File "/home/mailman/Mailman/Handlers/Scrubber.py", line 411, in save_attachment filename = Utils.oneline(msg.get_filename(''), lcset) File "/home/mailman/pythonlib/email/Message.py", line 724, in get_filename filename = self.get_param('filename', missing, 'content-disposition') File "/home/mailman/pythonlib/email/Message.py", line 607, in get_param for k, v in self._get_params_preserve(failobj, header): File "/home/mailman/pythonlib/email/Message.py", line 554, in _get_params_preserve params = Utils.decode_params(params) File "/home/mailman/pythonlib/email/Utils.py", line 337, in decode_params charset, language, value = decode_rfc2231(EMPTYSTRING.join(value)) File "/home/mailman/pythonlib/email/Utils.py", line 284, in decode_rfc2231 charset, language, s = parts ValueError: unpack list of wrong size
-- Mark Sapiro <msapiro@value.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
participants (2)
-
Kory Wheatley
-
Mark Sapiro