[Gajim-devel] plugin system

Yann Leboulanger asterix at lagaule.org
Thu Feb 18 22:00:59 CET 2010

Hi all,

I started to look seriously a plugin system branch, and use it to
dispatch events. I did a proof of concept patch. First I explain how
things used to work before:

XML stream -> xmpppy (parse XML) -> connection.py -> dispatch event to
GUI with all arguments

The way it works now:
XML stream -> xmpppy (parse XML) -> connection.py -> NEC (create an
HttpAuthReceivedEvent object, which extract data from stanza) -> GED
(dispatch it to handlers)

In case of HTTP_AUTH (the patch attached) a first handler is in
connection_handlers.py, and, if the option is set for that, sends answer
automatically and stop propagation
a second handler is in gui_interface.py and is called if first one
didn't stopped propagation, and shows a dialog to the user.

This is only a proof of concept and has to be used for all events. But
we need to decide what's the best with this branch.
I see 2 options:
 - we merge it to trunk, and start to develop in it. That should not
break anything why we slowly merge to this new event flow
 - release 0.14 as soon as possible, and merge it to trunk for 0.15 only.

Comments are more than welcome!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: auth_plugin.patch
Type: text/x-patch
Size: 7942 bytes
Desc: not available
URL: <http://www.lagaule.org/pipermail/gajim-devel/attachments/20100218/44629669/attachment.bin>

More information about the Gajim-devel mailing list