Re: Attn Malcolm: unicode serialization

2007-05-04 Thread Malcolm Tredinnick
Hey Jeremy, On Fri, 2007-05-04 at 19:44 -0500, Jeremy Dunck wrote: > Malcolm, > I noticed that Django's current serialization doesn't deal with unicode > well. Too true. :-) > > When using MySQLdb with utf8 as the encoding, charfields return > unicode objects. base.get_string_field break

Attn Malcolm: unicode serialization

2007-05-04 Thread Jeremy Dunck
Malcolm, I noticed that Django's current serialization doesn't deal with unicode well. When using MySQLdb with utf8 as the encoding, charfields return unicode objects. base.get_string_field breaks because it calls str() on the field, forcing python to use sys.getdefaultencoding(). As a res