[I18n-sig] Codecs for Big Five and GB 2312
Martin v. Loewis
martin@loewis.home.cs.tu-berlin.de
Tue, 31 Oct 2000 19:25:26 +0100
> u"abc".encode("mycodecs.my_utf_8")
>
> and the encodings search function will take care of the rest.
>
> Wouldn't this solve at least some of the problems ?
I don't think so. The class of applications that I think will need
codecs first are "internet" applications: processors of HTML, XML,
MIME. In all these cases, some well-established encoding name is used,
which should be provided by Python "as-is". That is, if you receive
data in "shift-jis", having to map this to "japanese.shift_jis" is
just the same as requiring that "japanese" is imported up-front. In
the applications that I see, the application does not want to know
what "shift-jis" is - it just wants Python to convert that to Unicode.
Regards,
Martin