Re: UnicodeString encoding
Christoph Zwerschke <[email protected]> Thu, 12 Mar 2009 18:07:40 +0100
| Newsgroups | gmane.comp.python.formencode |
|---|---|
| Message-ID | <[email protected]> |
Ian Bicking schrieb: > Changing the default behavior could mess up working code. I think it > would make sense to treat an encoding of None as do-not-encode (or > decode). A subclass of UnicodeString could have that value > (outputEncoding) default to None. Yes, that's exactly what my patch does: It uses NoDefault instead of None as the default value for inputEncoding and outputEncoding, treats None as "do no encode/decode" and falls back to the encoding set at the class level (utf-8 for the standard class) if nothing is specified. I've checked this in as r3805 now. Maybe we also want to add input and output encoding default attributes on the class level? There is currently only one common attribute for both. If we agree on the new behaviour, I will also update the docstring and unit tests. -- Christoph ------------------------------------------------------------------------------ Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are powering Web 2.0 with engaging, cross-platform capabilities. Quickly and easily build your RIAs with Flex Builder, the Eclipse(TM)based development software that enables intelligent coding and step-through debugging. Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com