[zope2-tracker] [Bug 246983] Re: Page Template: TALES string expr. unicode err.

LeoRochael leorochael at gmail.com
Tue Jan 5 12:15:28 EST 2010


This other patch includes the test in the patch above plus more tests
and a solution to this issue. The solution is a 15 line StringExpr
subclass that conditionally coerces the values to unicode using the
UnicodeConflictResolver.

Differently than I proposed, this patch is completely contained in
Zope2, and does not touch zope.tales. I'll probably start a discussion
later on zope-dev about the fact that the behaviour of string
expressions with Unicode strings is not completely defined in that
package.

If that discussion proves fruitful, the 15 line line fix above will no
longer be needed. but meanwhile, I'll assume silence is consent and
commit this patch to the Zope 2.12 branch and trunk if I don't receive
any comments to the contrary in 24h, as it fixes the breakages I had in
the body of code I'm maintaining.

Nils: I'd appreciate if you could check whether the fix in the patch
above also works for you.


** Also affects: zope2/2.12
   Importance: Undecided
       Status: New

** Also affects: zope2/trunk
   Importance: Undecided
     Assignee: Andreas Jung (ajung)
       Status: Confirmed

** Attachment added: "Proposed fix for 246983"
   http://launchpadlibrarian.net/37454895/resolveStringExprValuesThroughUnicodeConflictResolver.diff

-- 
Page Template: TALES string expr. unicode err.
https://bugs.launchpad.net/bugs/246983
You received this bug notification because you are a member of Zope 2
Developers, which is subscribed to Zope 2.


More information about the zope2-tracker mailing list