Edgewall Software
Modify

Ticket #1302 (closed defect: fixed)

Opened 7 years ago

Last modified 6 years ago

Crash when clicked "WikiRestructuredTextLinks"

Reported by: dserodio@… Owned by: jonas
Priority: high Milestone: 0.8.2
Component: wiki system Version: 0.8.1
Severity: major Keywords: docutils
Cc:
Release Notes:
API Changes:

Description

I installed trac, clicked on "Timeline", then "WikiRestructuredTextLinks", and got the following error:

Traceback (most recent call last):
  File "/usr/lib/python2.3/site-packages/trac/core.py", line 525, in cgi_start
    real_cgi_start()
  File "/usr/lib/python2.3/site-packages/trac/core.py", line 520, in real_cgi_start
    dispatch_request(path_info, args, req, env)
  File "/usr/lib/python2.3/site-packages/trac/core.py", line 435, in dispatch_request
    module.run()
  File "/usr/lib/python2.3/site-packages/trac/Module.py", line 44, in run
    self.render()
  File "/usr/lib/python2.3/site-packages/trac/Wiki.py", line 339, in render
    Formatter(self.req.hdf, self.env,self.db).format(self.page.text, out)
  File "/usr/lib/python2.3/site-packages/trac/WikiFormatter.py", line 549, in format
    self.handle_code_block(line)
  File "/usr/lib/python2.3/site-packages/trac/WikiFormatter.py", line 505, in handle_code_block
    self.out.write(self.code_processor(self.hdf, self.code_text, self.env))
  File "/usr/lib/python2.3/site-packages/trac/wikimacros/rst.py", line 209, in execute
    settings_overrides = {'halt_level':6})
  File "/usr/lib/site-python/docutils/core.py", line 371, in publish_string
    enable_exit_status=enable_exit_status)
  File "/usr/lib/site-python/docutils/core.py", line 513, in publish_programmatically
    output = pub.publish(enable_exit_status=enable_exit_status)
  File "/usr/lib/site-python/docutils/core.py", line 196, in publish
    output = self.writer.write(document, self.destination)
  File "/usr/lib/site-python/docutils/writers/__init__.py", line 72, in write
    self.translate()
  File "/usr/lib/site-python/docutils/writers/html4css1.py", line 103, in translate
    self.document.walkabout(visitor)
  File "/usr/lib/site-python/docutils/nodes.py", line 153, in walkabout
    child.walkabout(visitor)
  File "/usr/lib/site-python/docutils/nodes.py", line 153, in walkabout
    child.walkabout(visitor)
  File "/usr/lib/site-python/docutils/nodes.py", line 153, in walkabout
    child.walkabout(visitor)
  File "/usr/lib/site-python/docutils/nodes.py", line 153, in walkabout
    child.walkabout(visitor)
  File "/usr/lib/site-python/docutils/nodes.py", line 153, in walkabout
    child.walkabout(visitor)
  File "/usr/lib/site-python/docutils/nodes.py", line 145, in walkabout
    visitor.dispatch_visit(self)
  File "/usr/lib/site-python/docutils/nodes.py", line 1323, in dispatch_visit
    return method(node)
  File "/usr/lib/site-python/docutils/writers/html4css1.py", line 1050, in visit_reference
    assert len(node) == 1 and isinstance(node[0], nodes.image)
AssertionError

Attachments

Change History

comment:1 Changed 7 years ago by cboos@…

From TracInstall: docutils, version ≥ 0.3.3 (??) for WikiRestructuredText

What docutils version are you using?

comment:2 Changed 7 years ago by Artur (x-phile@…

I get this error too. I tried docutils 0.3.7 and then latest development snapshot. Both on Windows and Linux. Maybe some older docutils version will work?

comment:3 Changed 7 years ago by anonymous

I'm using docutils 0.3.7-2 (the -2 is the Debian revision). What version is Trac known to work with?

comment:4 Changed 7 years ago by cboos

That might be too recent… I'm using 0.3.5 on
Windows and Linux without any problem.

comment:5 Changed 7 years ago by Artur (x-phile@…

Yes, 0.3.5 works fine. But IMO this incompatibility should be mentioned in Trac's documentation.

comment:6 Changed 7 years ago by cboos

I added a link to this ticket in TracInstall

comment:7 Changed 7 years ago by mrowe

#1342 was closed as a duplicate of this bug.

comment:8 Changed 7 years ago by mrowe

A lot of digging reveals that this is specific to the directive form of link, such as .. trac:: #1. As it is a child of the "document" rather than a paragraph or such, docutils appears to take a code path that expects that it is an image. I'm not familiar enough with the internals of docutils to determine where the problem lies.

comment:9 Changed 7 years ago by mrowe

  • Component changed from general to wiki
  • Keywords docutils added
  • Milestone set to 0.9
  • Priority changed from normal to high
  • Severity changed from normal to major

comment:10 Changed 7 years ago by otavio

This bug was report to BTS of Debian project. Please do a look at: http://bugs.debian.org/301151.

I hope we can solve this before sarge since could be good to have a solid release in a so used distribution. Please, if possible, advice me if have news about it.

comment:11 Changed 7 years ago by otavio

Another possible thing is this bug be on docutils and not on trac. In this case I can contact the docutils maintainer and ask for a comment about it.

comment:12 Changed 7 years ago by mrowe

I would appreciate it if you could discuss it with someone familiar with docutils.

comment:13 Changed 7 years ago by otavio

I sent a mail to docutils maintainer, on Debian, asking about it and then he sent it to developers mailing list. I hope we should receive some information about it near.

Only one thing I don't agree with you is about the milestone of bug. I think it should be fixed for 0.8.2 and ASAP since it's a serious bug and it's hit a lot of users. Since it ocour after a clean install, it may cause a bad "first impression".

comment:14 Changed 7 years ago by mrowe

  • Milestone changed from 0.9 to 0.8.2

Thanks. I agree about the milestone.

comment:15 Changed 7 years ago by otavio@…

The message posted by docutils's maintainer can be viewed at:

http://sourceforge.net/mailarchive/forum.php?thread_id=6915620&forum_id=8812

comment:16 Changed 7 years ago by mrowe

  • Resolution set to fixed
  • Status changed from new to closed

Fixed in [1458] and merged to 0.8-stable branch in [1459]. Thanks for following this up otavio.

comment:17 Changed 7 years ago by otavio

You're welcome. I also did a upload to Debian fixing this bug and doing another trivial packaging related fix.

Thanks again.

View

Add a comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
The resolution will be deleted. Next status will be 'reopened'
to The owner will be changed from jonas. Next status will be 'closed'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.