R. David Murray added the comment:

Turns out even with as_string accepting a policy keyword, the example still 
failed.  It needs to be generating a bytes object, not a string.  Before I even 
realized that, though, I decided I wanted to add as_bytes (and __bytes__).  So 
the attached patch does that: adds policy to as_string, and adds new methods 
as_bytes and __bytes__ to Message.

This patch is only for 3.4.  The 3.3 patch will just delete that part of the 
policy example, so I'm not going to bother to upload it.

----------
keywords: +patch
stage: needs patch -> patch review
Added file: http://bugs.python.org/file31209/as_string_policy.patch

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue18600>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to