[Python-Dev] PEP 376 proposed changes for basic plugins support

Ian Bicking ianb at colorstudy.com
Mon Aug 2 18:57:23 CEST 2010


Just to add a general opinion in here:

Having worked with Setuptools' entry points, and a little with some Zope
pluginish systems (Products.*, which I don't think anyone liked much, and
some ways ZCML is used is pluginish), I'm not very excited about these.  The
plugin system that causes the least confusion and yet seems to accomplish
everything it needs is just listing objects in configuration -- nothing gets
activated implicitly with installation, and names are Python package/object
names without indirection.  The only thing I'd want to add is the ability to
also point to files, as a common use for plugins is adding ad hoc
functionality to an application, and the overhead of package creation isn't
always called for.  hg for example seems both simple and general enough, and
it doesn't use anything fancy.

Purely for the purpose of discovery and documentation it might be helpful to
have APIs, then some tool could show available plugins (especially if PyPI
had a query interface for this), or at least installed plugins, with the
necessary code to invoke them.

*Maybe* it would make sense to generalize the discovery of plugin types, so
that you can simply refer to an object and the application can determine
what kind of plugin it is.  But having described this, it actually doesn't
seem like a useful thing to generalize.

-- 
Ian Bicking  |  http://blog.ianbicking.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20100802/14e7893f/attachment.html>


More information about the Python-Dev mailing list