Re: Error: ASCII decoding error: ordinal not in range(128)

Yuri Smetsers <[email protected]>
Newsgroups gmane.comp.web.zope.silva.devel
Message-ID <[email protected]>
Hi Clemens,

> Please read TROUBLESHOOTONG.txt, especially the last section about unicode issues.

Reading it now. :)

 > A more detailled bug report would be really nice, as its usually hard 
to reproduce such an error.

Here you go:

Traceback (innermost last):
  Module ZPublisher.Publish, line 98, in publish
  Module ZPublisher.mapply, line 88, in mapply
  Module ZPublisher.Publish, line 39, in call_object
  Module Shared.DC.Scripts.Bindings, line 306, in __call__
  Module Shared.DC.Scripts.Bindings, line 343, in _bindAndExec
  Module Products.PythonScripts.PythonScript, line 307, in _exec
  Module None, line 26, in index_html
   - <PythonScript at /twin/index_html used for /twin/nieuws/item/opkikker>
   - Line 26
  Module Shared.DC.Scripts.Bindings, line 306, in __call__
  Module Shared.DC.Scripts.Bindings, line 343, in _bindAndExec
  Module Products.PageTemplates.ZopePageTemplate, line 228, in _exec
  Module Products.PageTemplates.PageTemplate, line 95, in pt_render
   - <ZopePageTemplate at /twin/content.html used for /twin/nieuws/item/opkikker>
  Module TAL.TALInterpreter, line 200, in __call__
  Module TAL.TALInterpreter, line 244, in interpret
  Module TAL.TALInterpreter, line 703, in do_useMacro
  Module TAL.TALInterpreter, line 244, in interpret
  Module TAL.TALInterpreter, line 734, in do_defineSlot
  Module TAL.TALInterpreter, line 244, in interpret
  Module TAL.TALInterpreter, line 682, in do_defineMacro
  Module TAL.TALInterpreter, line 244, in interpret
  Module TAL.TALInterpreter, line 414, in do_optTag_tal
  Module TAL.TALInterpreter, line 399, in do_optTag
  Module TAL.TALInterpreter, line 394, in no_tag
  Module TAL.TALInterpreter, line 244, in interpret
  Module TAL.TALInterpreter, line 592, in do_insertStructure_tal
  Module Products.PageTemplates.TALES, line 220, in evaluate
   - URL: /twin/nieuws/layout_macro.html
   - Line 100, Column 8
   - Expression: <PythonExpr getattr(here, view_method)()>
   - Names:
      {'container': <Silva Root instance twin>,
       'default': <Products.PageTemplates.TALES.Default instance at 0x87580c4>,
       'here': <Silva Article instance opkikker>,
       'loop': <SafeMapping instance at 9bb9088>,
       'modules': <Products.PageTemplates.ZRPythonExpr._SecureModuleImporter instance at 0x875dc8c>,
       'nothing': None,
       'options': {'args': (), 'view_method': 'view'},
       'repeat': <SafeMapping instance at 9bb9088>,
       'request': <HTTPRequest, URL=http://webserver.twindesign.nl:9673/twin/nieuws/item/opkikker/index_html>,
       'root': <Application instance at 9955160>,
       'template': <ZopePageTemplate at /twin/content.html used for /twin/nieuws/item/opkikker>,
       'traverse_subpath': [],
       'user': Anonymous User}
  Module Products.PageTemplates.ZRPythonExpr, line 47, in __call__
   - __traceback_info__: getattr(here, view_method)()
  Module Python expression "getattr(here, view_method)()", line 1, in <expression>
  Module Products.Silva.VersionedContent, line 212, in view
  Module Products.Silva.SilvaObject, line 281, in view
  Module Products.SilvaViews.MultiViewRegistry, line 151, in render_view
  Module Products.FileSystemSite.FSPythonScript, line 104, in __call__
  Module Shared.DC.Scripts.Bindings, line 306, in __call__
  Module Shared.DC.Scripts.Bindings, line 343, in _bindAndExec
  Module Products.FileSystemSite.FSPythonScript, line 160, in _exec
  Module None, line 5, in render_view
   - <FSPythonScript at /twin/service_views/SilvaNews/public/PlainArticle/render_view>
   - Line 5
  Module Shared.DC.Scripts.Bindings, line 306, in __call__
  Module Shared.DC.Scripts.Bindings, line 343, in _bindAndExec
  Module Products.FileSystemSite.FSPageTemplate, line 191, in _exec
  Module Products.FileSystemSite.FSPageTemplate, line 124, in pt_render
  Module Products.PageTemplates.PageTemplate, line 95, in pt_render
   - <FSPageTemplate at /twin/service_views/SilvaNews/public/PlainArticle/render_helper>
  Module TAL.TALInterpreter, line 200, in __call__
  Module TAL.TALInterpreter, line 244, in interpret
  Module TAL.TALInterpreter, line 592, in do_insertStructure_tal
  Module Products.PageTemplates.TALES, line 220, in evaluate
   - Line 23, Column 0
   - Expression: <PythonExpr view.get_content(version)>
   - Names:
      {'container': <DirectoryViewSurrogate instance at bfb06e0>,
       'default': <Products.PageTemplates.TALES.Default instance at 0x87580c4>,
       'here': <DirectoryViewSurrogate instance at bfb06e0>,
       'loop': <SafeMapping instance at ac11fa8>,
       'modules': <Products.PageTemplates.ZRPythonExpr._SecureModuleImporter instance at 0x875dc8c>,
       'nothing': None,
       'options': {'args': (),
                   'version': <PlainArticleVersion at /twin/nieuws/item/opkikker/14>},
       'repeat': <SafeMapping instance at ac11fa8>,
       'request': <HTTPRequest, URL=http://webserver.twindesign.nl:9673/twin/nieuws/item/opkikker/index_html>,
       'root': <Application instance at 9955160>,
       'template': <FSPageTemplate at /twin/service_views/SilvaNews/public/PlainArticle/render_helper>,
       'traverse_subpath': [],
       'user': Anonymous User}
  Module Products.PageTemplates.ZRPythonExpr, line 47, in __call__
   - __traceback_info__: view.get_content(version)
  Module Python expression "view.get_content(version)", line 1, in <expression>
  Module Products.FileSystemSite.FSPythonScript, line 104, in __call__
  Module Shared.DC.Scripts.Bindings, line 306, in __call__
  Module Shared.DC.Scripts.Bindings, line 343, in _bindAndExec
  Module Products.FileSystemSite.FSPythonScript, line 160, in _exec
  Module None, line 2, in get_content
   - <FSPythonScript at /twin/service_views/SilvaNews/public/PlainArticle/get_content>
   - Line 2
  Module Shared.DC.Scripts.Bindings, line 306, in __call__
  Module Shared.DC.Scripts.Bindings, line 343, in _bindAndExec
  Module Products.FileSystemSite.FSPageTemplate, line 191, in _exec
  Module Products.FileSystemSite.FSPageTemplate, line 124, in pt_render
  Module Products.PageTemplates.PageTemplate, line 95, in pt_render
   - <FSPageTemplate at /twin/service_widgets/top/field/mode_view/render>
  Module TAL.TALInterpreter, line 200, in __call__
  Module TAL.TALInterpreter, line 244, in interpret
  Module TAL.TALInterpreter, line 592, in do_insertStructure_tal
  Module Products.PageTemplates.TALES, line 220, in evaluate
   - Line 1, Column 0
   - Expression: <PythonExpr here.service_editor.renderElementsView(request.node)>
   - Names:
      {'container': <DirectoryViewSurrogate instance at c011640>,
       'default': <Products.PageTemplates.TALES.Default instance at 0x87580c4>,
       'here': <DirectoryViewSurrogate instance at c011640>,
       'loop': <SafeMapping instance at b5567c8>,
       'modules': <Products.PageTemplates.ZRPythonExpr._SecureModuleImporter instance at 0x875dc8c>,
       'nothing': None,
       'options': {'args': ()},
       'repeat': <SafeMapping instance at b5567c8>,
       'request': <HTTPRequest, URL=http://webserver.twindesign.nl:9673/twin/nieuws/item/opkikker/index_html>,
       'root': <Application instance at 9955160>,
       'template': <FSPageTemplate at /twin/service_widgets/top/field/mode_view/render>,
       'traverse_subpath': [],
       'user': Anonymous User}
  Module Products.PageTemplates.ZRPythonExpr, line 47, in __call__
   - __traceback_info__: here.service_editor.renderElementsView(request.node)
  Module Python expression "here.service_editor.renderElementsView(request.node)", line 1, in <expression>
  Module Products.XMLWidgets.EditorService, line 333, in renderElementsView
UnicodeError: ASCII decoding error: ordinal not in range(128)

Regards,
Yuri

Clemens Robbenhaar wrote:

>Hi Yuri,
>
> > Hello developers,
> > 
> > When loading some of newly added Silva documents, the following error 
> > occurs:
> > 
> > *Error Type: UnicodeError*
> > 
> > 
> >         Error Value: ASCII decoding error: ordinal not in range(128)
> > 
> > Most content is added by our webmaster, who uses an iMac (*sigh*) 
> > running Mac OS 9 and Mozilla 1.3 (hurray!), so I won't be able to 
> > reproduce the error.
>
> This should be browser independent, thus normally You should be able to
>reproduce this.
>
> > Zope and Silva are running on Debian Linux.
> > 
> > Is this a known bug? If more input is needed, please ask. :)
>
> Maybe. Please read TROUBLESHOOTONG.txt, especially the last section about
>unicode issues. A more detailled bug report would be really nice, as its
>usually hard to reproduce such an error.
>
>Cheers,
>Clemens
>
>  
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.