[Spambayes] Mailbox class in the spambayes project & python 2.2.1

Alexander Leidinger Alexander@Leidinger.net
Wed, 25 Sep 2002 13:28:58 +0200


at http://www.leidinger.net/20001001.freebsd-isp.txt.bz2 (40k) I have a
mbox which is responsible for this error:
Traceback (most recent call last):
  File "../../mboxcount.py", line 100, in ?
  File "../../mboxcount.py", line 90, in main
    goodn, badn = count(fname)
  File "../../mboxcount.py", line 58, in count
    for msg in mbox:
  File "/usr/local/lib/python2.2/mailbox.py", line 34, in next
    return self.factory(_Subfile(self.fp, start, stop))
  File "../../mboxcount.py", line 49, in _factory
    return email.message_from_file(fp)
  File "/home/netchild/work/src/spambayes/email/__init__.py", line 39, in message_from_file
    return _Parser(_class, strict=strict).parse(fp)
  File "/home/netchild/work/src/spambayes/email/Parser.py", line 48, in parse
    self._parsebody(root, fp)
  File "/home/netchild/work/src/spambayes/email/Parser.py", line 118, in _parsebody
    boundary = container.get_boundary()
  File "/home/netchild/work/src/spambayes/email/Message.py", line 677, in get_boundary
    return _unquotevalue(boundary.strip())
AttributeError: 'tuple' object has no attribute 'strip'

I haven't tried to reduce the unpacked ~200k file into a smaller one
which still produces this traceback because I think it should be easy
(with intimate knowledge of Message.py) to just add some debug output to
Message.py to find the problem.


     The three Rs of Microsoft support: Retry, Reboot, Reinstall.

http://www.Leidinger.net                       Alexander @ Leidinger.net
  GPG fingerprint = C518 BC70 E67F 143F BE91  3365 79E2 9C60 B006 3FE7