Edgewall Software
Modify

Opened 16 years ago

Closed 15 years ago

Last modified 15 years ago

#7684 closed defect (fixed)

Render error on error pages and wiki edits

Reported by: Daniel Nauck <dna@…> Owned by: Christian Boos
Priority: high Milestone: 0.12
Component: rendering Version: 0.12dev
Severity: normal Keywords: genshi051
Cc: info@… Branch:
Release Notes:
API Changes:
Internal Changes:

Description

I got the folling error with Trac 0.12dev-r7556.

My Environment:

Trac:  	0.12dev-r7556
Python: 	2.5.1 (r251:54863, Jul 31 2008, 23:20:23) [GCC 4.1.3 20070929 (prerelease) (Ubuntu 4.1.2-16ubuntu2)]
setuptools: 	0.6c6
SQLite: 	3.4.2
pysqlite: 	2.3.4
Genshi: 	0.5.1
mod_python: 	3.3.1
Pygments: 	0.8.1
Subversion: 	1.4.4 (r25188)
jQuery:	1.2.6

Traceback:

Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/Trac-0.12dev_r7556-py2.5.egg/trac/web/api.py", line 373, in send_error
    data, 'text/html')
  File "/usr/lib/python2.5/site-packages/Trac-0.12dev_r7556-py2.5.egg/trac/web/chrome.py", line 719, in render_template
    return stream.render(method, doctype=doctype)
  File "build/bdist.linux-i686/egg/genshi/core.py", line 179, in render
    return encode(generator, method=method, encoding=encoding, out=out)
  File "build/bdist.linux-i686/egg/genshi/output.py", line 60, in encode
    return _encode(u''.join(list(iterator)))
  File "build/bdist.linux-i686/egg/genshi/output.py", line 311, in __call__
    for kind, data, pos in stream:
  File "build/bdist.linux-i686/egg/genshi/output.py", line 753, in __call__
    for kind, data, pos in stream:
  File "build/bdist.linux-i686/egg/genshi/output.py", line 592, in __call__
    for kind, data, pos in stream:
  File "build/bdist.linux-i686/egg/genshi/output.py", line 698, in __call__
    for kind, data, pos in chain(stream, [(None, None, None)]):
  File "build/bdist.linux-i686/egg/genshi/output.py", line 532, in __call__
    for ev in stream:
  File "build/bdist.linux-i686/egg/genshi/core.py", line 283, in _ensure
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/core.py", line 283, in _ensure
    for event in stream:
  File "/usr/lib/python2.5/site-packages/Trac-0.12dev_r7556-py2.5.egg/trac/web/chrome.py", line 771, in _strip_accesskeys
    for kind, data, pos in stream:
  File "build/bdist.linux-i686/egg/genshi/core.py", line 283, in _ensure
    for event in stream:
  File "/usr/lib/python2.5/site-packages/Trac-0.12dev_r7556-py2.5.egg/trac/web/chrome.py", line 760, in _generate
    for kind, data, pos in stream:
  File "build/bdist.linux-i686/egg/genshi/core.py", line 283, in _ensure
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 569, in _include
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/template/markup.py", line 298, in _match
    ctxt, start=idx + 1, **vars):
  File "build/bdist.linux-i686/egg/genshi/template/markup.py", line 298, in _match
    ctxt, start=idx + 1, **vars):
  File "build/bdist.linux-i686/egg/genshi/template/markup.py", line 245, in _match
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 543, in _exec
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 533, in _eval
    for event in substream:
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 496, in _eval
    for kind, data, pos in stream:
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 551, in _flatten
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/core.py", line 283, in _ensure
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/path.py", line 141, in _generate
    subevent = stream.next()
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 569, in _include
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/template/markup.py", line 234, in _strip
    event = stream.next()
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 543, in _exec
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 533, in _eval
    for event in substream:
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 496, in _eval
    for kind, data, pos in stream:
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 551, in _flatten
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/core.py", line 283, in _ensure
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/path.py", line 141, in _generate
    subevent = stream.next()
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 569, in _include
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/template/markup.py", line 234, in _strip
    event = stream.next()
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 543, in _exec
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 496, in _eval
    for kind, data, pos in stream:
  File "build/bdist.linux-i686/egg/genshi/template/base.py", line 551, in _flatten
    for event in stream:
  File "build/bdist.linux-i686/egg/genshi/filters/i18n.py", line 213, in __call__
    new_substream = list(self(substream, ctxt, msgbuf=msgbuf))
  File "build/bdist.linux-i686/egg/genshi/filters/i18n.py", line 213, in __call__
    new_substream = list(self(substream, ctxt, msgbuf=msgbuf))
  File "build/bdist.linux-i686/egg/genshi/filters/i18n.py", line 213, in __call__
    new_substream = list(self(substream, ctxt, msgbuf=msgbuf))
  File "build/bdist.linux-i686/egg/genshi/filters/i18n.py", line 213, in __call__
    new_substream = list(self(substream, ctxt, msgbuf=msgbuf))
  File "build/bdist.linux-i686/egg/genshi/filters/i18n.py", line 213, in __call__
    new_substream = list(self(substream, ctxt, msgbuf=msgbuf))
  File "build/bdist.linux-i686/egg/genshi/filters/i18n.py", line 170, in __call__
    search_text=False, msgbuf=msgbuf)
  File "build/bdist.linux-i686/egg/genshi/filters/i18n.py", line 201, in __call__
    msgbuf.append(kind, data, pos)
  File "build/bdist.linux-i686/egg/genshi/filters/i18n.py", line 379, in append
    param = self.params.pop(0)
IndexError: pop from empty list

Attachments (0)

Change History (11)

comment:1 by Remy Blank, 16 years ago

The traceback doesn't help much… Could you please give us some more information about the context of the error? What operations did lead to the error? Is it reproducible? Anything special about the data that should have been displayed?

comment:2 by Daniel Nauck <dna@…>, 16 years ago

Hello,

this happens on every error page and also when i click on the wiki "Edit" button.

comment:3 by Remy Blank, 16 years ago

I cannot reproduce this here using [7575]. You might want to try the following:

  • Update to the latest trunk.
  • Disable all plugins, then add one after the other until it breaks.

Is your Trac instance publicly accessible?

comment:4 by Daniel Nauck <dna@…>, 16 years ago

comment:5 by Christian Boos, 16 years ago

Keywords: genshi added

See #7525. It seems that Genshi 0.5.1 is not recent enough for trunk (with or without Babel, I don't know) but according to #7525 a more recent version should work.

This needs to be documented somewhere or put in the setup.py requirements.

comment:6 by Daniel Nauck <dna@…>, 16 years ago

It works with Genshi 0.6dev-r960

in reply to:  5 comment:7 by Remy Blank, 16 years ago

Replying to cboos:

It seems that Genshi 0.5.1 is not recent enough for trunk (with or without Babel, I don't know) but according to #7525 a more recent version should work.

For reference, I am running trunk with 0.5.1 and it seems to work ok. Babel is not installed, though. And I have only tested tracd, not mod_python.

comment:8 by info@…, 15 years ago

Getting the same problem here with Trac r7621 and Babel 0.9.4. Will switch to 0.6-dev as suggested to see if this fixes it.

comment:9 by info@…, 15 years ago

Cc: info@… added

Err, that should be Genshi 0.5.1 in the previous comment.

comment:10 by Christian Boos, 15 years ago

Keywords: genshi051 added; genshi removed
Resolution: fixed
Status: newclosed

With [7727] I now also get this on the Timeline with Babel 0.9.4 and Genshi 0.5.1.

This is related to the introduction of a i18n:msg tag in the timeline.html template. The wiki_edit.html also has one, as well as the error.html.

So this effectively means that 0.12dev with Babel has stopped to be compatible with Genshi 0.5.1. Updated the requirement in setup.py, in r7728.

One could eventually fix 0.5.1 and maybe it even works with 0.5-stable, but better spend that time on getting Genshi's advanced-18n/0.6 done.

comment:11 by Remy Blank, 15 years ago

Owner: set to Christian Boos

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Christian Boos.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Christian Boos to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.