[Product-Developers] Re: Re: Re: UnicodeDecodeError

Andreas Jung lists at zopyx.com
Tue Mar 25 14:44:32 UTC 2008



--On 25. März 2008 15:06:59 +0100 Gilles Lenfant 
<gilles.lenfant at ingeniweb.com> wrote:

> Le 25 mars 08 à 14:51, Andreas Jung a écrit :
>>
>
> [...]
>
>>
>> How clearer can I be: don't touch the encoding - never ever. And it
>> is perfectly ok for Plone not to touch the default encoding. Implicit
>> charset conversions are evil...as I wrote several times.
>
>
> Hi,
>
> Does this mean that such code...
>
>      dummy = str(someunicode)
>
> ... should be forbidden ?
>

YES! You should *ever* use explicit charset conversion using

dummy = someunicodeste.encode(your_encoding)

If the Pycon 2008 videos should be online at some time in the future, 
consider watching the Unicode talk.

-aj

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 194 bytes
Desc: not available
URL: <http://lists.plone.org/pipermail/plone-product-developers/attachments/20080325/f25ca48c/attachment.asc>


More information about the Product-Developers mailing list