[Zope-dev] Re: (SOLVED) Showstopper UnicodeDecodeError on Zope import???

Nick Bower nicholas.bower at jrc.it
Fri Oct 8 13:08:02 EDT 2004


We'd had a very simple multi-lingual CMF document written for us a 
couple of years ago (basically a folderish object with sub-objects in 
with unicode content and titles).  I found these objects were the cause 
of the import failures and that if I uninstalled the product and then 
imported, to break the said objects, then re-installed the product, 
everything would work.

Unicode characters were of course being used in the catloged object 
titles - maybe zope doesn't permit this?  I don't know.

Anyway, pretty sad way to make something work, having to intentionally 
break it, but there you go.  The funny thing is that there's not 
actually anything wrong with this product afaik and no traceback 
mentioned it.  Only someone with more in depth zope knowledge could 
comment on this.


Nick Bower wrote:
> I'm trying to import a zexp export (a Plone site actually) from a 
> windows workstation to a zope server I built on Linux RH9 but it fails 
> with a UnicodeDecodeError:
> 
> ...
> Module Products.ZCTextIndex.Lexicon, line 69, in sourceToWordIds
> Module Products.ZCTextIndex.Lexicon, line 135, in _getWordIdCreate
> 
> UnicodeDecodeError: 'ascii' codec can't decode byte 0xef in position 5: 
> orginal not in range(128).
> 
> What is confusing is that the zexp *will* import to another linux zope 
> build I have (on Mdk10) and sys.getdefaultencoding() and 
> locale.getdefaultlocale() on the 2 linux machines are almost the same 
> (the working one reports "en_GB, utf"/ascii and the non-working one 
> reports "en_US, utf"/ascii), so I think this is a red herring.  I can't 
> for the life of me work out what is going wrong as I built python myself 
> on both Linux machines exactly the same.
> 
> Can anyone help me please???
> 
> Thanks, Nick
> 
> _______________________________________________
> Zope-Dev maillist  -  Zope-Dev at zope.org
> http://mail.zope.org/mailman/listinfo/zope-dev
> **  No cross posts or HTML encoding!  **
> (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce
> http://mail.zope.org/mailman/listinfo/zope )
> 



More information about the Zope-Dev mailing list