[Zope3-dev] template path unicode bug in zcml

Christophe Combelles ccomb at free.fr
Sat Aug 11 13:54:17 EDT 2007


I've found a small bug related to zcml parsing, I would like to know if this is 
already known or maybe fixed in 3.4, or if this is just a configuration problem 
in my instance:

my instance is located in a path containing some unicode char,
and when I use a "template=" attribute in a browser:page attribute,
I get a ascii decode error while the zcml parser tries to build the path of the 
template file.


     args = toargs(context, *self.argdata)
   File "/usr/lib/python2.4/site-packages/zope/configuration/config.py", line 
1383, in toargs
     args[str(name)] = field.fromUnicode(s)
   File "/usr/lib/python2.4/site-packages/zope/configuration/fields.py", line 
291, in fromUnicode
     return self.context.path(u)
   File "/usr/lib/python2.4/site-packages/zope/configuration/config.py", line 
256, in path
     return os.path.join(basepath, filename)
   File "/usr/lib/python2.4/posixpath.py", line 65, in join
     path += '/' + b
zope.configuration.xmlconfig.ZopeXMLConfigurationError: File ...
     ZopeXMLConfigurationError: File ...
     ZopeXMLConfigurationError: File ...
     ZopeXMLConfigurationError: File ...
  UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 28: 
ordinal not in range(128)

More information about the Zope3-dev mailing list