Submitted by : schlenk at: 2007-07-17T07:03:36-07:00 (10 years ago)
Name :
Category : Severity : Status :
Optional subject :  
Optional comment :

When creating a wiki page with an accented title (e.g. german umlauts), the 'edit' link throws and UnicodeDecodeError?.

The exception is only raised when a localized browser is used, not with a browser with en-us localization. (e.g. Windows Firefox 2.0.0.4 en-us works, de-de does not, same for 1.5.0.12, IE 7 german also shows the exception). Probably simple unicode string mishandling.

Traceback (innermost last):

Module ZPublisher?.Publish, line 115, in publish Module ZPublisher?.mapply, line 88, in mapply Module ZPublisher?.Publish, line 41, in call_object Module Products.ZWiki.Views, line 470, in editform Module Shared.DC.Scripts.Bindings, line 311, in __call__ Module Shared.DC.Scripts.Bindings, line 348, in _bindAndExec Module Products.CMFCore.FSPageTemplate?, line 195, in _exec Module Products.CacheSetup?.patch_cmf, line 18, in FSPT_pt_render Module Products.CacheSetup?.patch_utils, line 9, in call_pattern Module Products.CMFCore.FSPageTemplate?, line 134, in pt_render Module Products.CacheSetup?.patch_cmf, line 68, in PT_pt_render Module Products.CacheSetup?.patch_utils, line 9, in call_pattern Module Products.PageTemplates.PageTemplate, line 104, in pt_render

  • <FSPageTemplate? at /intra/editform used for /intra/cdb.10/storage/storage-wiki/Verschl_c3_bcsselungUndStorage>

Module TAL.TALInterpreter?, line 238, in __call__ Module TAL.TALInterpreter?, line 281, in interpret Module TAL.TALInterpreter?, line 749, in do_useMacro Module TAL.TALInterpreter?, line 281, in interpret Module TAL.TALInterpreter?, line 457, in do_optTag_tal Module TAL.TALInterpreter?, line 442, in do_optTag Module TAL.TALInterpreter?, line 437, in no_tag Module TAL.TALInterpreter?, line 281, in interpret Module TAL.TALInterpreter?, line 780, in do_defineSlot Module TAL.TALInterpreter?, line 281, in interpret Module TAL.TALInterpreter?, line 457, in do_optTag_tal Module TAL.TALInterpreter?, line 442, in do_optTag Module TAL.TALInterpreter?, line 437, in no_tag Module TAL.TALInterpreter?, line 281, in interpret Module TAL.TALInterpreter?, line 728, in do_defineMacro Module TAL.TALInterpreter?, line 281, in interpret Module TAL.TALInterpreter?, line 772, in do_defineSlot Module TAL.TALInterpreter?, line 281, in interpret Module TAL.TALInterpreter?, line 715, in do_condition Module TAL.TALInterpreter?, line 281, in interpret Module TAL.TALInterpreter?, line 310, in do_startEndTag Module TAL.TALInterpreter?, line 356, in do_startTag

UnicodeDecodeError?: 'ascii' codec can't decode byte 0xc3 in position 14: ordinal not in range(128)

Versions? --betabug, Tue, 17 Jul 2007 07:07:56 -0700 reply

What Zwiki and Zope versions are we talking about?

... --schlenk, Tue, 17 Jul 2007 08:23:07 -0700 reply

The Plone/Zope Version is from Plone-2.5.2-UnifiedInstaller?.tgz (http://plone.org/products/plone/releases)

ZWiki according to the ControlPanel? is Version "ZWiki-0-59-0" ZWikiFolder is "ZWikiFolder 1.0.0"

Can reproduce --betabug, Sat, 28 Jul 2007 10:36:45 -0700 reply

Yes, I can reproduce it. I'm using Zwiki from darcs, a Zope 2.9 test instance, and installed FireFox? 2.0.0.5 in German in a W2K Virtual Machine (no funny questions about the last point, hey, you've gotta test somewhere :-). While FF was still the en-US version, /editform on a page with German "umlauts" in the page title worked fine. Now with FF in German it bombs. Interesting.

Fix (not yet in darcs) --betabug, Sat, 28 Jul 2007 10:46:46 -0700 reply

The following one-line change fixes it for Zwiki from darcs:

hunk ./skins/zwiki/editform.pt 64
-                           tal:attributes="value python:newname;" />
+                           tal:attributes="value python:here.talsafe(newname)" />

Once I get the tests to pass (currently I get 4 failing tests for a fresh "darcs get"ed Zwiki), I will send it to darcs.

Fix in darcs --betabug, Sat, 28 Jul 2007 15:00:45 -0700 reply

Sent in the fix now, this should fix it for the Zwiki from darcs.

Actually not in darcs, send didn't work --betabug, Sun, 29 Jul 2007 05:53:37 -0700 reply

darcs send didn't work, "Deferred: Connection refused by mail.joyful.com".

apparently made it into darcs, closing --betabug, Sun, 05 Aug 2007 03:03:16 -0700 reply

Status: open => closed

great --simon, Sun, 05 Aug 2007 10:40:23 -0700 reply

Nice catch, thank you both.