Ticket #5415 (closed defect: fixed)

Opened 3 years ago

Last modified 2 years ago

xmlrpcplugin-r6077 trunk breaks TRAC 0.11 with Agilo installed on Debian Lenny

Reported by: Ameise71@web.de Assigned to: osimons
Priority: normal Component: XmlRpcPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.11

Description (Last modified by osimons)

I get an error from Apache when activating xmlrpcplugin on my Debian Linux box running Trac 0.11.1. Seems to be caused by the plugin.

Traceback:

Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/trac/web/api.py", line 339, in send_error
    'text/html')
  File "/usr/lib/python2.5/site-packages/trac/web/chrome.py", line 684, in render_template
    data = self.populate_data(req, data)
  File "/usr/lib/python2.5/site-packages/trac/web/chrome.py", line 592, in populate_data
    d['chrome'].update(req.chrome)
  File "/usr/lib/python2.5/site-packages/trac/web/api.py", line 169, in __getattr__
    value = self.callbacks[name](self)
  File "/usr/lib/python2.5/site-packages/trac/web/chrome.py", line 460, in prepare_request
    for category, name, text in contributor.get_navigation_items(req):
  File "/usr/lib/python2.5/site-packages/trac/versioncontrol/web_ui/browser.py", line 295, in get_navigation_items
    if 'BROWSER_VIEW' in req.perm:
  File "/usr/lib/python2.5/site-packages/trac/perm.py", line 523, in has_permission
    return self._has_permission(action, resource)
  File "/usr/lib/python2.5/site-packages/trac/perm.py", line 537, in _has_permission
    check_permission(action, perm.username, resource, perm)
  File "/usr/lib/python2.5/site-packages/trac/perm.py", line 424, in check_permission
    perm)
  File "/usr/lib/python2.5/site-packages/trac/perm.py", line 282, in check_permission
    get_user_permissions(username)
  File "/usr/lib/python2.5/site-packages/trac/perm.py", line 343, in get_user_permissions
    for requestor in self.requestors:
  File "/usr/lib/python2.5/site-packages/trac/core.py", line 67, in extensions
    return filter(None, [component.compmgr[cls] for cls in extensions])
  File "/usr/lib/python2.5/site-packages/trac/core.py", line 204, in __getitem__
    component = cls(self)
  File "/usr/lib/python2.5/site-packages/trac/core.py", line 108, in maybe_init
    init(self)
  File "build/bdist.linux-i686/egg/tracrpc/api.py", line 158, in __init__
    __import__('tracrpc', ['__version__']).__version__))
  File "build/bdist.linux-i686/egg/tracrpc/__init__.py", line 10, in <module>
  File "build/bdist.linux-i686/egg/tracrpc/web_ui.py", line 21, in <module>
ImportError: cannot import name exception_to_unicode

Attachments

t5415-exception_to_unicode-r6070.diff (1.8 kB) - added by osimons on 06/22/09 21:51:32.
Compat workaround for newer Trac util method.

Change History

06/22/09 21:50:48 changed by anonymous

Bummer. That method was added to Trac in trac:changeset:7835. Which means 0.11.3 or newer. I'll copy it into tracrpc.util as a backup for older Trac versions. Attaching patch - could you please verify it?

06/22/09 21:51:32 changed by osimons

  • attachment t5415-exception_to_unicode-r6070.diff added.

Compat workaround for newer Trac util method.

06/22/09 22:49:22 changed by Ameise71

Looks good! Patched the files here and it does not crash anymore! Would highly appreciate to integrate that into one of the next revisions. Thanks for very quick help!

06/23/09 01:54:05 changed by osimons

  • description changed.

Thanks for testing. I'll commit shortly.

(Reformatted description)

06/23/09 02:01:52 changed by osimons

  • status changed from new to closed.
  • resolution set to fixed.

(In [6078]) XmlRpcPlugin: Fix for use of a Trac method only available on 0.11.3 or higher. Made a compat-workaround for now.

Closes #5415.


Add/Change #5415 (xmlrpcplugin-r6077 trunk breaks TRAC 0.11 with Agilo installed on Debian Lenny)




Change Properties
Action