Issue1443875
Created on 2006-03-06 04:41 by tkikuchi, last changed 2009-04-22 14:35 by ajaksu2.
| File name |
Uploaded |
Description |
Edit |
Remove |
|
charset.py.patch
|
tkikuchi,
2006-03-06 04:41
|
charset.py.patch |
|
|
|
ja-nonlegit.py
|
tkikuchi,
2006-03-13 23:35
|
non-legitimate ja characters example |
|
|
|
msg49660 - (view) |
Author: Tokio Kikuchi (tkikuchi) |
Date: 2006-03-06 04:41 |
|
email/charset.py has convert() function to incorporate
using different charset for input and output for a
language like Japanese. Because the email user agent
in Japan frequently use characters outside the range of
legitimate JIS charset, these messages are shunted in
mailman delivery. Here is a patch to handle this case
by replacing the characters by '?' using the 'errors'
parameter in unicode/encode functions.
This patch includes the unicode string conversion patch
in #1368247.
|
|
msg49661 - (view) |
Author: Barry A. Warsaw (barry) |
Date: 2006-03-12 13:09 |
|
Logged In: YES
user_id=12800
Do you have a test case for this? #1368247 includes one just
for the encoding of unicode strings, but not for the error
argument. If you can include a simple test case, then I'll
add this patch.
|
|
msg49662 - (view) |
Author: Tokio Kikuchi (tkikuchi) |
Date: 2006-03-13 23:35 |
|
Logged In: YES
user_id=67709
Thanks! Here is an example program which fails on 4.0a
without the patch.
|
|
msg49663 - (view) |
Author: Martin v. Löwis (loewis) |
Date: 2007-03-05 13:15 |
|
I'm -1 on this patch as-is. It changes the default error handling behavior from 'strict' to 'replace', for this method. This is a choice that the caller of these methods should make, so I think the default value for the error handling should be 'strict'. If then it is meaningful in mailman to set this to 'replace', this is mailman's choice. Python should never, on its own, create moji-bake.
If you revise this patch, please provide the test case as a patch to Lib/email/test somehow (probably patching both test_email and test_email_renamed).
|
|
msg49664 - (view) |
Author: Tokio Kikuchi (tkikuchi) |
Date: 2007-03-13 11:58 |
|
Ok, I worked a little on the code to propagate the choice of 'strict' or 'replace' but there are many we should fix. And we should fix the application, mailman, also. The problem is only related to Japanese and we'd rather find workarounds elsewhere. I put the priority of this patch lowest. Thanks for your comments.
|
|
| Date |
User |
Action |
Args |
| 2009-04-22 14:35:26 | ajaksu2 | set | keywords:
+ easy |
| 2009-03-30 22:56:23 | ajaksu2 | link | issue1685453 dependencies |
| 2009-03-21 00:45:44 | ajaksu2 | set | stage: patch review type: feature request versions:
+ Python 3.1, Python 2.7, - Python 2.4 |
| 2006-03-06 04:41:30 | tkikuchi | create | |
|