This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author labrat
Recipients barry, labrat, pas, r.david.murray
Date 2014-11-07.10:31:11
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1415356272.29.0.313184863412.issue22684@psf.upfronthosting.co.za>
In-reply-to
Content
In email._header_value_parser._Folded.append_if_fits, if I shift:

            if token.has_fws:
                ws = token.pop_leading_fws()
                if ws is not None:
                    self.stickyspace += str(ws)
                    stickyspace_len += len(ws)
                token._fold(self)
                return True

to:

            if token.has_fws:
                ws = token.pop_leading_fws()
                if ws is not None:
                    self.stickyspace += str(ws)
                    stickyspace_len += len(ws)
                    token._fold(self)
                    return True

I can avoid the recursion.

The problem seems to be that the "a aaaa…aaa" token/part contains folding white space, but doesn't *start* with folding whitespace.  Maybe the folding should try to split on existing FWS, instead of just trying to pop leading FWS?
History
Date User Action Args
2014-11-07 10:31:12labratsetrecipients: + labrat, barry, r.david.murray, pas
2014-11-07 10:31:12labratsetmessageid: <1415356272.29.0.313184863412.issue22684@psf.upfronthosting.co.za>
2014-11-07 10:31:12labratlinkissue22684 messages
2014-11-07 10:31:11labratcreate