Hello,

can you point me to existing, open-source mailman plugins?

I want to write a plugin, which fires on all subscriptions,
unsubscriptions and configuration changes.

This code:

def subscribe_events(e):
    print('EVENT', e)

@implementer(IPlugin)
class SievePlugin:
    def __init__(self):
        print('XXX')
        zope.event.subscribers.append(subscribe_events)

    def post_hook(self):
        print('YYY')
        zope.event.subscribers.append(subscribe_events)


prints:
XXX
EVENT x...@example.org joined zzz.udoma.bapha.be
EVENT ab c <m...@example.org> joined zzz.udoma.bapha.be

or 
XXX
EVENT x...@example.org left zzz.udoma.bapha.be

on `mailman addmembers/mailman delmembers`.  But it does not trigger a
UnsubscriptionEvent or SubscriptionEvent.

Greetings
  Дилян
_______________________________________________
Mailman-Developers mailing list -- mailman-developers@python.org
To unsubscribe send an email to mailman-developers-le...@python.org
https://mail.python.org/mailman3/lists/mailman-developers.python.org/
Mailman FAQ: https://wiki.list.org/x/AgA3

Security Policy: https://wiki.list.org/x/QIA9

Reply via email to