-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 05/14/2012 08:13 AM, Michael Howitz wrote: > Log message for revision 125861: In version 3.7.2 msgids and default > values where forced to be unicodes. This was too strict because at > least the TAL extractor returns UTF-8 encoded default values. Fixed > this by allowing the default value to be a string again.
<snip> > --- zope.app.locales/trunk/src/zope/app/locales/extract.py 2012-05-14 > 08:50:08 UTC (rev 125860) +++ > zope.app.locales/trunk/src/zope/app/locales/extract.py 2012-05-14 > 12:13:47 UTC (rev 125861) @@ -97,7 +97,7 @@ msgstr "" <BLANKLINE> > > - Unicode can be used in msgids and default values + Unicode can > be used in msgids and default values: > >>>> entry = POTEntry(Message(u"\u263B", default=u"\u253A")) >>>> entry.write(FakeFile()) > @@ -106,6 +106,16 @@ msgstr "" <BLANKLINE> > > + But msgid might be an ascii encoded string and `default` might be > a + string with the DEFAULT_ENCODING, too: + + >>> entry = > POTEntry(Message("Oe", default="\xd6")) + >>> > entry.write(FakeFile()) + #. Default: "\326" + msgid "Oe" + > msgstr "" + <BLANKLINE> + """ Hmm, I'm running into a test failure where the Message constructor blows up with a decode error for the 'default' value here. Does that ring any bells for anyone? I know we can't be depending on a sys.setdefaultencoding hack. Tres. - -- =================================================================== Tres Seaver +1 540-429-0999 tsea...@palladion.com Palladion Software "Excellence by Design" http://palladion.com -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk/t6b4ACgkQ+gerLs4ltQ4OAwCeK2Cm+Xm/OLy+adZGfOkQx/hk CakAoLQFXbtqQU9Jlm1ZfgtD58RwJ7wE =kFK2 -----END PGP SIGNATURE----- _______________________________________________ Zope-Dev maillist - Zope-Dev@zope.org https://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - https://mail.zope.org/mailman/listinfo/zope-announce https://mail.zope.org/mailman/listinfo/zope )