enthought / envisage

Envisage is a Python-based framework for building applications whose functionalities can be extended by adding "plug-ins".
http://docs.enthought.com/envisage/
Other
80 stars 26 forks source link

Deprecate the include and exclude traits on PluginManager #544

Closed mdickinson closed 1 year ago

mdickinson commented 1 year ago

This PR deprecates use of the include and exclude traits on the PluginManager base class, on the grounds that those traits don't currently work as intended (judging the intention from the tests), and that it's not fully clear how they were intended to work.

The main clients for these traits seem to be the EggBasketPluginManager and the PackagePluginManager, both of which are now deprecated. The EggPluginManager also makes use of this, though it duplicates and overwrites the functionality instead of inheriting it from the PluginManager base class.

Technical details:

There may well be a use-case for filtering plugins, but I think we should design a working, self-consistent solution based on that use-case when it comes up in practice. I'd also expect that we may want to allow more general (and more pluggable) filtering than the current fnmatch-restricted solution. In the meantime, I don't think there's much value in keeping include and exclude around.

xref: #531