1. Python plugin systems

    There is a lot of interesting information about creating plugin architectures using Python all over the web, but its in fairly disparate places. This is an overview of the documentation that I found as of April 2010.

    Firstly Dr André Roberge has some very interesting posts, as well as a talk at PyCon 2009 on Blip.tv entitled Plugins and monkeypatching: increasing flexibility, dealing with inflexibility. He is also the author of Crunchy which uses a plugin system. He goes on to write about his experiences in creating a plugin architecture on his blog, over 6 parts starting here on part 1.

    Marty Alchin, the author of Pro Django has an interesting couple of pages in that same book about creating a simple plugin system, and the snippet of code is on djangosnippets.com. He also has an excellent blog post about implementing a plugin architecture, it also talks about Django but is fairly non-specific.

    William E. Hart over 2009-2010 has also been researching Python Plugin Frameworks, his overview is on his blog and he is also the author of the PyUtilib Component Architecture. This was very recently released and so hasn’t gathered much momentum as of this post but looks very promising indeed.

    Zope. The big one is the Zope Component Architecture. I must admit, that looking into it I think its overkill, I don’t like the configuration utility or the overhead it introduces – just to use it requires a lot of extra Zope modules. However google for it if you are interested in learning further.

    Yapsy. Yapsy is interesting, looks extremely lightweight, has been around for a few years, is currently on version 1.7 and serves as a good starting point. It has no external dependancies.

    SprinklesPy. SprinklesPy is also very lightweight but I am not sure that development is active on it (2006 was the last mention of it being used that I found), or that it has anyone in the community using it (a benefit I believe if you are implementing a system that you are not creating yourself.)

    Trac is the one component architecture that frequently gets mentioned, and it has a very decent user base. However, ripping the plugin system out might be more work than is reasonable.

    Examples of Plugin use in the wild:

    Other interesting links:

    It is clear to me that there is no correct way of implementing plugins and you have to pick based upon the needs of your project, but this should serve as a good starting point. I will add and update this post as my knowledge grows.