[Spambayes] BoundaryError: multipart message with no definedboundary

Tony Meyer tameyer at ihug.co.nz
Thu Sep 16 07:18:12 CEST 2004

[It doesn't appear that this messages to spambayes at python.org has been
answered yet - sorry about that! I've been away and so are catching up with
the messages. Please ignore if I'm wrong and this has been resolved

> It looks like the email is causing a program exception,
> which means it is not being classified as spam.
> X-Spambayes-Exception: Traceback (most recent call last):
>  .  File "sb_server.pyc", line 471, in onRetr
>  .  File "spambayes\message.pyc", line 247, in setPayload
>  .  File "email\Parser.pyc", line 245, in _parsebody
>  .BoundaryError: multipart message with no defined boundary

What is happening here is that the message is malformed (either
deliberately, or because of bad spamware).  As such, SpamBayes isn't able to
make sense of it to be able to figure out whether it looks like ham or spam.
So it just adds the exception header so you know it's been looked at, and
leaves it.

New versions of SpamBayes (1.1 and beyond) will use a newer version of the
email library, which handles all such problems very cleanly.  For the
moment, it's not really worth us duplicating this work to add code for
specific problems, unless they are extremely common.

Normally, I'd suggest that you setup your mail client to move all messages
with the exception header to the unsure folder, since the chances of them
being spam are very high.  However, OE can't filter on arbitrary headers, so
that's not a possibility here.  Would it be useful to be able to have the
exception header also added to the recipient list/subject like the
classifications are?  (Like "Exception,Regular subject here").

=Tony Meyer

Please always include the list (spambayes at python.org) in your replies
(reply-all), and please don't send me personal mail about SpamBayes. This
way, you get everyone's help, and avoid a lack of replies when I'm busy.

More information about the Spambayes mailing list