Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#3778 closed defect (wontfix)

Plugin does not respect NeverNotifyUpdaterPlugin

Reported by: hju@… Owned by: CStrac
Priority: normal Component: FlexibleReporterNotificationPlugin
Severity: major Keywords:
Cc: Trac Release: 0.11


First thank you for this little plugin. I was looking for the same issue and was thinking about an enhancement of the AdvancedTicketWorkflowPlugin. This is the better way I think.

We are using email2trac and want to notify the reporter as you mentioned in your description.

There is a lttle problem with NeverNotifyUpdaterPlugin which is no longer operating after installation of this plugin!

Reason seems to be that NeverNotifyUpdaterPlugin uses the same procedure:

4 	def get_recipients(self, tktid):
48	        if not notify_updater:
49 	            filter_out = True
50 	#             if notify_reporter and (updater == self.reporter):
51 	#                 filter_out = False
52 	#             if notify_owner and (updater == self.owner):
53 	#                 filter_out = False
54 	            if filter_out:
55 	                torecipients = [r for r in torecipients if r and r != updater]
56 	                ccrecipients = [r for r in ccrecipients if r and r != updater]
57 	        elif updater:
58 	            torecipients.append(updater)

Looks like that the behaviour depends on order of loading the eggs.

Is there a way to fix this? Perhaps in respecting each other?

Attachments (0)

Change History (2)

comment:1 Changed 8 years ago by CStrac

Resolution: wontfix
Status: newclosed

Both the plugins override the same method "get_recipients". Therefore I dont think they can mutually co-exist. Any two plugins overriding a method may not mutually co-exist.

But the functionality of both the plugins can be included in a single plugin.

comment:2 Changed 8 years ago by hju@…

Sorry for the little delay...

This is exactly what I did. I included the NeverNotifyUpdaterPlugin-Code into this plugin creating a new version 0.0.2

The feature is activated by the new option NeverNotifyUpdater=true in [Notification] section of trac.ini


    1010        notify_updater = self.config.getbool('notification',
    1111                                             'always_notify_updater')
    1212    for_reporting = self.config.getlist('notification','reporter_states')
     13        for_updating = self.config.getbool('notification','NeverNotifyUpdater')
    1314        ccrecipients = self.prev_cc
    1415        torecipients = []
    1516        cursor = self.db.cursor()
    5354    for updater, in cursor:
    5455        break
     57    # Check for NeverNotifyUpdater==true (included from NeverNotifyUpdaterPlugin)
     58        if (not notify_updater) and (for_updating):
     59           filter_out = True
     60           if filter_out:
     61              torecipients = [r for r in torecipients if r and r != updater]
     62              ccrecipients = [r for r in ccrecipients if r and r != updater]
     63        elif updater:
     64              torecipients.append(updater)
    5867        return (torecipients, ccrecipients)

Modify Ticket

as closed The owner will remain CStrac.
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.