1. plurk
  2. solace
  3. Issues
Issue #11 new

Goes 500 when "show revisions" is requested

Atamert Ölçgen
created an issue

I get server error when I try to view post revisions. Some of my settings are below:

{{{

!python

DATABASE_URI = 'postgres://***' DEFAULT_LANGUAGE = 'tr' LANGUAGE_SECTIONS = ['tr'] THEME = 'doorusu' # custom theme , works fine otherwise THEME_PATH = *** }}}

Traceback is attached. I would be happy to provide additional info if required:

{{{

!traceback

UnicodeDecodeError: 'ascii' codec can't decode byte 0xc4 in position 32 }}}

Comments (14)

  1. Armin Ronacher

    Weird. I cannot reproduce that here.

    Can you tell me what versions of Genshi and creoleparser you are using? Maybe there was an API change from unicode to bytes or the other way round.

  2. Atamert Ölçgen reporter

    this is ls -1 of lib/python2.5

    Babel-0.9.4-py2.5.egg Creoleparser-0.6.1-py2.5.egg easy-install.pth Genshi-0.5.1-py2.5-linux-i686.egg Jinja2-2.1.1-py2.5-linux-i686.egg simplejson-2.0.9-py2.5-linux-i686.egg site.py site.pyc Solace-0.1-py2.5.egg SQLAlchemy-0.5.5-py2.5.egg WebDepCompress-0.1.1-py2.5.egg Werkzeug-0.5.1-py2.5.egg

    Maybe I can extract the data that causes this error (if you can tell me where to look for it). Or I can e-mail you the whole db dump?

  3. Atamert Ölçgen reporter

    oops, again:

    Babel-0.9.4-py2.5.egg
    Creoleparser-0.6.1-py2.5.egg
    easy-install.pth
    Genshi-0.5.1-py2.5-linux-i686.egg
    Jinja2-2.1.1-py2.5-linux-i686.egg
    simplejson-2.0.9-py2.5-linux-i686.egg
    site.py
    site.pyc
    Solace-0.1-py2.5.egg
    SQLAlchemy-0.5.5-py2.5.egg
    WebDepCompress-0.1.1-py2.5.egg
    Werkzeug-0.5.1-py2.5.egg
    
  4. Atamert Ölçgen reporter

    format_creole() returns Unicode, format_creole_diff() doesn't. (solace.utils.formatting)

    >>> from solace.utils.formatting import format_creole, format_creole_diff
    >>> format_creole(u'Test')
    u'<p>Test</p>\n'
    >>> format_creole_diff(u'Test', u'tess')
    '<p><del>Test</del><ins>tess</ins></p>\n'
    
  5. Atamert Ölçgen reporter

    http://bitbucket.org/muhuk/solace/changeset/2c697415dda6/ should be fixing this one:

    (solace_muhuk)muhuk@debian:~/code/solace_muhuk/src$ hg diff                     
    diff -r 423a3345cbde solace/utils/formatting.py                                 
    --- a/solace/utils/formatting.py        Wed Jan 27 22:52:40 2010 +0200          
    +++ b/solace/utils/formatting.py        Thu Jan 28 13:52:25 2010 +0200          
    @@ -40,7 +40,7 @@
         """Renders a creole diff for two texts."""
         differ = StreamDiffer(_parser.generate(old),
                               _parser.generate(new))
    -    return differ.get_diff_stream().render('html')
    +    return differ.get_diff_stream().render('html', encoding=None)
    
  6. Log in to comment