[Patches] [ python-Patches-486375 ] Use charset in email.Utils.encode

noreply@sourceforge.net noreply@sourceforge.net
Mon, 03 Dec 2001 11:26:41 -0800


Patches item #486375, was opened at 2001-11-27 22:45
You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=486375&group_id=5470

Category: Library (Lib)
Group: None
>Status: Closed
>Resolution: Rejected
Priority: 7
Submitted By: Mikhail Zabaluev (mzabaluev)
Assigned to: Barry Warsaw (bwarsaw)
Summary: Use charset in email.Utils.encode

Initial Comment:
Here's a patch that makes email.Utils.encode actually
_use_ its charset parameter. Note: a string is encoded
into the specified character set using the 'replace'
mode in order to provide high tolerance for missing
characters, typical for email applications.
The patch also slightly optimizes the code around
(cough cough).

----------------------------------------------------------------------

>Comment By: Barry Warsaw (bwarsaw)
Date: 2001-12-03 11:26

Message:
Logged In: YES 
user_id=12800

Sorry, but this isn't correct.  email.Utils.encode() states
that the argument "s" must already be encoded in the given
character set.  The charset argument is required because
Python can't guess what charset s is encoded in.

I'm rejecting this patch, although I'll install the
optimizations from it.

----------------------------------------------------------------------

You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=486375&group_id=5470