Opened 14 years ago

Closed 7 years ago

#8003 closed defect (wontfix)

AnnouncementSystem failed then no Components are defined

Reported by: Victor S. Sverdlin Owned by:
Priority: normal Component: AnnouncerPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.12


Then "component" list is empty the plugin falls with error:

2010-10-29 16:13:39,008 Trac[api] ERROR: AnnouncementSystem failed.
Traceback (most recent call last):
  File "build/bdist.freebsd-8.0-STABLE-i386/egg/announcerplugin/", line 351, in _real_send
    x for x in sp.get_subscriptions_for_event(evt) if x
  File "build/bdist.freebsd-8.0-STABLE-i386/egg/announcerplugin/", line 351, in <genexpr>
    x for x in sp.get_subscriptions_for_event(evt) if x
  File "build/bdist.freebsd-8.0-STABLE-i386/egg/announcerplugin/subscribers/", line 25, in get_subscriptions_for_event
    for subscriber in self._get_membership(ticket['component']):
  File "build/bdist.freebsd-8.0-STABLE-i386/egg/announcerplugin/subscribers/", line 39, in _get_membership
    """, ('announcer_joinable_component_' + component, "1"))
TypeError: cannot concatenate 'str' and 'NoneType' objects

Attachments (0)

Change History (5)

comment:1 Changed 14 years ago by Robert Corsaro

Disable the joinable components plugin. I'll leave the ticket open as we should check this case, but it makes no sense to have the joinable components plugin enabled if you don't use components. (unless it's just that none have been created yet, i guess).

comment:2 Changed 14 years ago by Victor S. Sverdlin

Excuse me my next question - I am new to trac. I cant see joinable components in ini file nor in admin panel. How to disable it?

comment:3 Changed 13 years ago by Danny Sauer

This code in

    def get_subscriptions_for_event(self, event):
        if event.realm == 'ticket':
            ticket =
            if event.category in ('changed', 'created', 'attachment added'):
                for subscriber in self._get_membership(ticket['component']):
                    self.log.debug("TicketComponentSubscriber added '%s " \
                            "(%s)' for component '%s'"%(
                            subscriber[1], subscriber[2], ticket['component']))
                    yield subscriber

should probably use a default value for the component rather than just trusting that there is a component value set. That would suppress this failure even if the component subscriber, err, component was enabled (which is the default, IIRC). Personally, I'd add a get_ticket_component method rather than directly referencing the array, but the details are less important. :)

comment:4 Changed 9 years ago by Ryan J Ollos

Owner: Robert Corsaro deleted

comment:5 Changed 7 years ago by Ryan J Ollos

Resolution: wontfix
Status: newclosed

Modify Ticket

Change Properties
Set your email in Preferences
as closed The ticket will remain with no owner.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment

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

Note: See TracTickets for help on using tickets.