plugin development best practices

Flavio fccoelho at gmail.com
Thu Feb 22 08:22:12 EST 2007


On Feb 22, 11:00 am, "Diez B. Roggisch" <d... at nospam.web.de> wrote:
> Flavio wrote:
> > Hi,
>
> > Nowadays the addition of functionality to programs by means  of
> > plugins is very frequent.
>
> > I want to know the opinions of experienced Python developers about the
> > best practices when it comes to developing a plugin system for a
> > Python package.
>
> > Should plugins be modules in a separate package?
> > Should there be a registry  of available plugins? how would such a
> > registry  be implemented? etc.
>
> There have been a gazillion discussions about this on this newsgroup/mailing
> list. Searching the archives will get you to them.
>
> The dynamic nature of python makes a whole range of options available.
> Depending on what you want to do (how are the plugins made available and so
> on), one or the other might be preferable.
>
> One relatively current development is the usage of setuptools "entry-points"
> feature, which is precisely made for discovering installed plugins:
>
> http://peak.telecommunity.com/DevCenter/setuptools#dynamic-discovery-...
>
> Diez

Thanks Diez,

I will search the archives. I am aware of the setuptools feature It is
quite nice. But the documentation is not very clear on how to define
"entry point groups" on the importing end, i.e. how to prepare a an
application to accept plugins it doesn't even now exist.

Flavio




More information about the Python-list mailing list